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 |
Blessed1978
Yak Posting Veteran
97 Posts |
Posted - 2014-02-11 : 20:33:30
|
I have wrote a tsql that has multiple joinshowever i keep on getting error message that sysdate is an in valid column sys dateon this lineAND created_date > sysdate()-1and end_date <= sysdate()please assist |
|
khtan
In (Som, Ni, Yak)
17689 Posts |
Posted - 2014-02-11 : 20:38:31
|
if you are using Microsoft SQL Server, it should be getdate() KH[spoiler]Time is always against us[/spoiler] |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2014-02-12 : 00:29:28
|
quote: Originally posted by Blessed1978 I have wrote a tsql that has multiple joinshowever i keep on getting error message that sysdate is an in valid column sys dateon this lineAND created_date > sysdate()-1and end_date <= sysdate()please assist
seehttp://visakhm.blogspot.in/2012/12/different-ways-to-implement-date-range.html------------------------------------------------------------------------------------------------------SQL Server MVPhttp://visakhm.blogspot.com/https://www.facebook.com/VmBlogs |
|
|
Lamprey
Master Smack Fu Yak Hacker
4614 Posts |
Posted - 2014-02-12 : 11:40:35
|
quote: Originally posted by khtan if you are using Microsoft SQL Server, it should be getdate() KH[spoiler]Time is always against us[/spoiler]
Or the (newer) SYSTADETIME() function. |
|
|
khtan
In (Som, Ni, Yak)
17689 Posts |
Posted - 2014-02-12 : 21:26:22
|
quote: Originally posted by Lamprey
quote: Originally posted by khtan if you are using Microsoft SQL Server, it should be getdate() KH[spoiler]Time is always against us[/spoiler]
Or the (newer) SYSTADETIME() function.
you mean SYSDATETIME() ? KH[spoiler]Time is always against us[/spoiler] |
|
|
|
|
|