01-22-2023 09:07 PM
Hey all,
Is there any way to convert a UST date/time to an IST date/time?
Any help will be appreciated.
Thank you.
Solved! Go to Solution.
01-23-2023 12:27 AM
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
01-23-2023 12:27 AM
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
01-23-2023 12:53 AM
thanks a lot!
01-23-2023 12:40 AM
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.
01-23-2023 12:53 AM
thank you Aleksandar…