Converting UST date and time to IST date and time

Hey all,

Is there any way to convert a UST date/time to an IST date/time?
Any help will be appreciated.

Thank you.

Hi @FatemaShakir ,

You can try the following expression:

Date.parse(Date.now()).toLocaleDateTimeString({"timeZone":"Asia/Kolkata", "format":"yyyy-MM-dd HH:mm"})

It converts current datetime in IST timezone.

Also, you can take a look at this documentation about Date Functions and Properties in SnapLogic.

These are the Supported Timezones in SnapLogic.

BR,
Marjan

3 Likes

Hi @FatemaShakir,

If you want to keep the typeof of the field as Date then you can try using the following expression:
Date.parse(Date.now().toLocaleDateTimeString({"timeZone":"Asia/Kolkata"}) + " Asia/Kolkata")

BR,
Aleksandar.

3 Likes

thanks a lot!

1 Like

thank you Aleksandar…

1 Like