A Southwestern adventurer striking out into the badlands of the Midwest for fun, profit, and for a wife who wouldn't move back to the Southwest :)
Monday, May 12, 2014
SQL Dates in Where Clauses
I always forget how to do this, so I'm making a post more for my quick reference than anyone else's. Anyway, this format should work not matter what culture you format your dates in...using Microsoft SQL Server variants anyway...
WHERE datetime_column BETWEEN'20081220 00:00:00.000'AND'20081220 23:59:59.997'