To get the dates between two dates you need to follow the following process:
You need to put those two dates between single quotes in this way:
SELECT Date, TotalAllowance
FROM Calculation
WHERE EmployeeId = 1 and Date between '2011/02/25' and '2011/02/27'
Are you interested in learning SQL from the basics! Refer to this video on SQL provided by Intellipaat:
Or, you can use the below code:
SELECT Date, TotalAllowance
FROM Calculation
WHERE EmployeeId = 1 and Date >= '2011/02/25' and Date <= '2011/02/27'
You can learn in-depth about SQL statements, queries and become proficient in SQL queries by enrolling in our industry-recognized SQL course.