DBAsupport.com Forums - Powered by vBulletin
Results 1 to 3 of 3

Thread: dbtimezone

  1. #1
    Join Date
    Mar 2006
    Location
    Charlotte, NC
    Posts
    865

    dbtimezone

    Hi,

    Our client in Fiji is going for DST change starting from this year. When I am querying the views (created using cre_tz_views.sql) i found dbtimezome is different in some databases. In some databases it is +12, in some +5, and in some -7.

    The query I used is 'select dbtimezone from dual;'

    None of the applications are using names timezone data types.

    Appreciate your input to know how the difference in dbtimezone makes difference.

    Thanks,
    Vijay Tummala

    Try hard to get what you like OR you will be forced to like what you get.

  2. #2
    Join Date
    Dec 1999
    Posts
    217
    The database takes the time from its server. So whatever timezone the server is set to the database will show that timezone.

    Hope this answers your question.

    Chintzs

  3. #3
    Join Date
    Mar 2006
    Location
    Charlotte, NC
    Posts
    865
    yes, I agree that database takes time from server. But I don't agree the same for timezones. In the below example from one of my servers, OS time zone seems to be GMT+12 and dbtimezone is +00:00 but still is showing the date /time correctly.

    So, I am trying to understand the user of dbtimezone.

    oracle@a1mumsum02$ date -u
    Wed Nov 25 08:39:04 GMT 2009
    oracle@a1mumsum02$ sqlplus '/as sysdba'

    SQL*Plus: Release 10.2.0.3.0 - Production on Wed Nov 25 20:39:11 2009

    Copyright (c) 1982, 2006, Oracle. All Rights Reserved.


    Connected to:
    Oracle Database 10g Enterprise Edition Release 10.2.0.3.0 - 64bit Production
    With the Partitioning, OLAP and Data Mining options

    SQL> !date
    Wed Nov 25 20:39:30 FJT 2009

    SQL> select dbtimezone from dual;

    DBTIME
    ------
    +00:00

    SQL> alter session set nls_date_format='DD-MON-YY HH24:MI:SS';

    Session altered.

    SQL> select sysdate from dual;

    SYSDATE
    ------------------
    25-NOV-09 20:39:50
    Vijay Tummala

    Try hard to get what you like OR you will be forced to like what you get.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Click Here to Expand Forum to Full Width