用SELECT SESSIONTIMEZONE, CURRENT_DATE FROM DUAL; 察看当前时差多少,然后用 ALTER SESSION SET TIME_ZONE = '-8:0'; 调整时差,-8是调整的小时数
CURRENT_DATE returns the current date in the session time zone, in a value in the Gregorian calendar of datatype DATE
SYADATE是当前database的时间,这个时间应该不会有误差的吧,我看你的问题可能是SESSIONTIMEZONE的问题,如果是dbtimezone有误差就采用1楼的方法 SYSDATE returns the current date and time. Requires no arguments. In distributed SQL statements, this function returns the date and time on your local database
察看当前时差多少,然后用
ALTER SESSION SET TIME_ZONE = '-8:0';
调整时差,-8是调整的小时数
SYSDATE returns the current date and time. Requires no arguments. In distributed SQL statements, this function returns the date and time on your local database