Microsoft
Software
Hardware
Network
Question : Date Comparison in MSSQL
Hello, I'm trying to compare two dates from two inline views in my where clause.
Both of the selects in my views work correctly, these fields are dates.
I want to verify that avail.period is before the date alloc_end.alloc_end from another inlline.
Like....
Where
avail.period <= alloc_end.alloc_end AND.....
Thanks in advance, this simple issue is killing me.
Answer : Date Comparison in MSSQL
Use the BETWEEN operator.
SELECT * ...
WHERE avail.period BETWEEN date1 AND date2
Random Solutions
Webcam VX-5000
a generic way to capture the passed in parameter values in a SQL Stored Procedure
creating users in MS Access
Message size limited using SendObject?
Publishing Site
Get only Day and month from datetime
Computer Browsing (My Network Places)
Outlook Anywhere Config on sbs 2008 (RPC over HTTP)
Acrobat Activex Control setview method
Installing Visual Web Developer 2008 Express