Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.misc -> Re: SYSDATE and timezone
In article <9p9gbt$f99$00$1_at_news.t-online.com>, "Nicolas says...
>
>I want to check the server time against the local time. Receiving the local
>time (using delphi) and the timezone is not the problem. But how to do it
>from Oracle?
>
>select sysdate from dual returns the current time including the timezone on
>the server. Or does I am wrong?
>
sysdate from dual returns the current time IN THE servers timezone (not including -- the timezone component is not available with sysdate).
In 9i, you can get a timestamp with timezone. In 8i there is no timezone support in the database.
see
http://asktom.oracle.com/pls/ask/f?p=4950:8:::::F4950_P8_DISPLAYID:452820143983
for methods to retrieve the server timezone using Java or C called from the database in 8i and 8.0.
>Regards
>
>Nicolas
>
>
-- Thomas Kyte (tkyte@us.oracle.com) http://asktom.oracle.com/ Expert one on one Oracle, programming techniques and solutions for Oracle. http://www.amazon.com/exec/obidos/ASIN/1861004826/ Opinions are mine and do not necessarily reflect those of Oracle CorpReceived on Mon Oct 01 2001 - 05:52:46 CDT