I have c# aspx.net with ms SQL server and have one question about SQL
assume I have a web form and come with start date and end date. the format is 20181201 and 20181231 and they are an integer.
and I have to run a SQL statement like below.
select top 1 * from transacation_history where deposit_date >= 20181201 and deposit <= 20181231
I should use between statement? but I do not know how to do that.
1. Which one run faster?
2. I will convert it into stored procedure. In this logic, is it best practice in ms sql?