ToDateTime function returns false date time value

Hi,

We have an API that returns a date time parameter as an integer. When I test it, I saw that it returns a weird value. The integer value is 1737814632147. Returned value is "57039-02-26T06:42:27.000Z".

I tried to convert int to date in JS and it returns "2025-01-25T14:17:12.000Z", so I expect Cloud to do the same.

Am I doing something wrong?

Regards.

Looking at number it looks closer to a UNIX timestamp.
10 digits is the number of seconds, 13 is in milliseconds.

If Unix then its the number of seconds since 01/Jan/1970
You need to add the number of seconds to that date to get the datetime stamp you probably want.
Depending on accuracy required I guess you could "drop" the milliseconds

Hi,

Thank you so much for your help, removing last three digits has fixed the problem.

Best regards!

This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.