【发布时间】:2016-08-24 05:18:09
【问题描述】:
我正在尝试获取我的 Oracle 11g 数据库的时区。我运行以下查询:
select dbtimezone from dual;
DBTIMEZONE
-------
+00:00
然后我尝试了以下查询并检查了数据库的属性以查看时区:
select property_name, property_value from database_properties;
Property_Name | PROPERTY_VALUE
---------------------------------------------- -----
DBTIMEZONE .... 00:00
现在我想更改数据库的时区。为此,我运行以下查询:
alter database set time_zone='-06:00';
数据库集 TIME_ZONE='-06:00' 已更改。
现在,当我尝试通过查询获取时区时:
select dbtimezone from dual;
DBTIMEZONE
-------------
+00:00
这里没有反映变化。
但是当我检查数据库属性中的时区时,我得到了更改的时区:
select property_name, property_value, description from database_properties;
Property_Name |属性值
----------------------------------------------
DBTIMEZONE .....-06:00
那么为什么 Dual 表没有显示更改的时区?
【问题讨论】:
标签: sql oracle oracle11g oracle-sqldeveloper