SET TIME ZONE
Use the SET TIME ZONE
command to specify the time zone that should be used to interpret date and time values.
Syntax
SET TIME ZONE { time_zone | LOCAL | DEFAULT };
Parameters
Parameter | Description |
---|---|
time_zone | Specifies the time zone using a valid time zone name, such as "America/New_York" or "Asia/Shanghai". You can find a list of all possible time_zone values here |
LOCAL | Sets the time zone to the system's local time zone. |
DEFAULT | Sets the time zone to the server's default time zone. |
Examples
SET TIME ZONE "America/New_York";
SET TIME ZONE LOCAL;
SET TIME ZONE DEFAULT;