RE: Convertion of time with NEW_TIME

  • From: "Bill Coulam" <bill.coulam@xxxxxxxx>
  • To: <lucdemanche@xxxxxxxxx>, <oracle-l@xxxxxxxxxxxxx>
  • Date: Tue, 11 Jan 2005 11:25:57 -0600

I've seen desperate attempts to make the timezone magically appear like this
before. It isn't pretty. Good luck my friend.

The DATE datatype is timezone agnostic.

If you know what timezone it was stored in, say systemwide all DATEs where
recorded in EST because that's what the host machine was set to, you're

If you stored the timezone in another column along with the DATE to indicate
what timezone applied when the record was written, you're golden.

Otherwise, you're sunk.

I'd be very happy to be corrected and learn something new...

- bill c.

-----Original Message-----
From: oracle-l-bounce@xxxxxxxxxxxxx
[mailto:oracle-l-bounce@xxxxxxxxxxxxx]On Behalf Of Luc Demanche
Sent: Tuesday, January 11, 2005 10:27 AM
To: oracledba@xxxxxxxxxxx; oracle-l@xxxxxxxxxxxxx
Subject: Convertion of time with NEW_TIME

Hi gurus,

- Oracle 8.1.7

I need to convert the local time to GMT, I want to use the NEW_TIME
function, but I need the abbreviation for the current timezone (EST).

I was looking with SESSIONTIMEZONE from dual, but it gives me the
offset, not the timezone abbreviation.  The code may be distributed
across time zones so I must find a dynamic solution.

Because we still are with Oracle8i, I can't use TIMESTAMP datatype ...

Can you help me either a) get the abbreviated time zone region name,
or b) tell me another way of converting any DATE to GMT?


Luc Demanche
Oracle DBA
(514) 867-9977


Other related posts: