Automatic Timestamp Macro

Automatic Timestamp Macro

Hi,

I found this topic and I think this is still a problem with UniDac:

When I use an SQL like ".... {timestamp '......'] ..." this works fine except for one client where I get an error:

 La conversion d'un type de données varchar en type de données datetime a créé une valeur hors limites.

I looked at the code and the converted SQL looks like this:
CREATED between CONVERT(DATETIME, '2023-05-01 00:00:00') and 
                   CONVERT(DATETIME, '2023-05-31 23:59:59') 

Now the funny thing is, if the client runs the query with the console of SQL Server Studio, he doesn't get an error. I think the problem is, that you don't set the "style" in the CONVERT function and in my case here it expects 0-12am/pm time or another problem with timezone offset.


Regards
Christian