work on Sql server 2000. i want to get the current server date and time then want to compare it with my table column EntryDate .How to?
Declare @id datetime
Select @id = DATEPART(hour,GETDATE())
SELECT [Name],[BirthDate],[Email]
FROM Customers3 where BirthDate<=@id-1 AND BirthDate>=@id
want to get on the range value like @id=10.I want to get those values whose are between 9 to 10