Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
superkid
Starting Member
5 Posts |
Posted - 2003-07-09 : 22:49:05
|
Good Day,1)I would like to know on how to go about comaparing an input date with the system date. 2)And also on how to go about comparing the difference in months and year when the user key in as dd/mm/yy. I would like to compare the months and year only (mm/yy).SELECT * FROM tableWHERE (Expiry > "sysdate")and (Expiry > & dtMonth &) ----> To compare difference in mthsORDER BY Expiry; |
|
Stoad
Freaky Yak Linguist
1983 Posts |
Posted - 2003-07-10 : 03:11:17
|
WHEREDateDiff ("m", Expiry, Date()) > 0 ' seek already expired items--- Date() is embedded VBA function- Vit |
 |
|
|
|
|