Home Forums SQL Server 2008 T-SQL (SS2K8) Selecting Data by Date for last five days AND avoiding weekend dates RE: Selecting Data by Date for last five days AND avoiding weekend dates
miles_lesperance
SSC Eights!
Points: 805
More actions
April 16, 2014 at 1:06 pm
#1706561
In your WHERE clause, you could try:
WHERE DATEPART(dw, getdate()) in (2, 3, 4, 5, 6)
That should give you only weekdays.