Hi There,
I am a newbie on SQL qieries and I am trying to run a query on a date/time filed to get yesterdays data.
Here is my test query ran from SQL analyzer:
select * from mvs_store_all_d ata_time_change where mvs_creation_da te = {fn NOW() }
The error I am getting is:
Server: Msg 241, Level 16, State 1, Line 1
Syntax error converting datetime from character string.
I assume it is to do with the format of this field I am trying to query and may need to be converted?
Any help will be much appreciated.
Cheers,
Riaan.
I am a newbie on SQL qieries and I am trying to run a query on a date/time filed to get yesterdays data.
Here is my test query ran from SQL analyzer:
select * from mvs_store_all_d ata_time_change where mvs_creation_da te = {fn NOW() }
The error I am getting is:
Server: Msg 241, Level 16, State 1, Line 1
Syntax error converting datetime from character string.
I assume it is to do with the format of this field I am trying to query and may need to be converted?
Any help will be much appreciated.
Cheers,
Riaan.
Comment