The # sign will not be recognized in SQL Server as a string delimiter. You need to use single quotes as shown in the following examples.
USE Northwind
GO
SELECT *
FROM Orders
WHERE ShippedDate = '07-16-1996'
SELECT *
FROM Orders
WHERE ShippedDate < '1996.07.16'
SELECT *
FROM Orders
WHERE ShippedDate LIKE '%1996%'
hi,
sql server have date funcations include DATEADD, GETDATE and DATEDIFF function,
this funcations will help you calculate date.
Hello,
Here is a good start point:
http://www.databasejournal.com/features/mssql/article.php/2197931
http://www.stanford.edu/~bsuter/sql-datecomputations.html
I hope this helps.