Simplifying time zone management shift using SYSDATE_AT_DBTIMEZONE
As mentioned, another parameter has been introduced recently – SYSDATE_AT_DBTIMEZONE
– which provides the same functionality as the previously described translation profiles. It is associated with the session and converts sysdate
references to local client date and time values by specifying the precise difference between the database and client time zones. The following commands show the principles and results:
select dbtimezone from dual; --> +09:00 alter session set SYSDATE_AT_DBTIMEZONE=false; select sysdate, current_date from dual; --> SYSDATE CURRENT_DATE --> 08.02.2022 14:56:00 08.02.2022 14:56:00 alter session set SYSDATE_AT_DBTIMEZONE=true; select sysdate, current_date from dual; --> SYSDATE ...