In most accounting and financial databases, dates need to be compared without
the time component. Here's how to strip out the time from getdate() ... or any
other datetime field
-- Date select : get only the date, time = midnight
declare @date1 smalldatetime
select @date1 = convert (smalldatetime, convert(varchar(10),getdate(),101) )
|
|