ToLocal

The ToLocal() function converts a UTC date to a local date with the given timezone (TZ database name). You can find the time zones used in wem in the list of IANA Standard Time zones.

This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.

Returns the local date with the given timezone.

Returns null if the timezone argument is not recognized.

Syntax

ToLocal(utcdate, timezone)

ToLocal(date(2020,8,16,15,37), "Europe/Amsterdam") =>Result: 8/16/2020 17:37​

ToLocal(date(2020,8,16,15,37), "Australia/Melbourne") =>Result: 8/17/2020 01:37

ToLocal(date(2020,8,16,15,37), "unrecognised TZ") =>Result: unknown

Parameters

Last updated