Question
SQL Between dates
I am trying to pull information between 2 argument dates.
Select offHours, tsCode, toDate
FROM timeSheetDays
WHERE uniqname = '#arguments.uniqname#'
AND TODate BETWEEN #arguments.startDate# and #arguments.endDate#
It comes out as:
Select offHours, tsCode, toDate FROM timeSheetDays WHERE uniqname = 'wkolcz' AND TODate BETWEEN 2008-06-1 and 2008-06-31
But I am not getting any results. What am I missing? I am using SQL server.
Select offHours, tsCode, toDate
FROM timeSheetDays
WHERE uniqname = '#arguments.uniqname#'
AND TODate BETWEEN #arguments.startDate# and #arguments.endDate#
It comes out as:
Select offHours, tsCode, toDate FROM timeSheetDays WHERE uniqname = 'wkolcz' AND TODate BETWEEN 2008-06-1 and 2008-06-31
But I am not getting any results. What am I missing? I am using SQL server.
