Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: running a process (oracle db) with modified system time

Re: running a process (oracle db) with modified system time

From: Igor Laletin <ilaletin_at_usa.net>
Date: 17 May 2004 17:23:02 -0700
Message-ID: <f9226414.0405171623.20da2f77@posting.google.com>


Barry Margolin <barmar_at_alum.mit.edu> wrote in message news:<barmar-A8D1F0.00210017052004_at_comcast.dca.giganews.com>...
> In article <f9226414.0405161636.4515fcc_at_posting.google.com>,
> ilaletin_at_usa.net (Igor Laletin) wrote:
>
> > Jarek 'bacza' Baczynski <jarek_at_nie.lubie.spamu.invalid> wrote in message
> > news:<slrn.pl.cadde9.3vvpmv9.jarek_at_Jarek.Baczynski>...
[...]
> > > is it possible to write some piece of code that catches some syscalls
> > > and returns modified time? if it is, how can I do that?

> > You need it only if you want to change time on a fly.

... and if you need to go more that +- 1 day.

> > The easiest way is to set TZ env variable before you start up the
> > instance and the listener. You can even have different times in
> > different sessions if you start several listeners with different TZ's
> > and connect via Net.
>
> That would change the way the time is displayed to humans, but won't
> have any effect on the times used internally within the program. Those
> times are simply the interval since the epoch.

We are not talking just any program which may or may not use TZ. Oracle server process calls gettimeofday (on HP-UX anyway) to get UTC time. After that it _uses_ TZ to shift it to a proper time zone. The adjusted time is used by the client. You can select it, insert into a table etc. Easy to check before starting to argue.

Cheers,
Igor

-- 
Barry Margolin, barmar_at_alum.mit.edu
Arlington, MA
*** PLEASE post questions in newsgroups, not directly to me ***
Received on Mon May 17 2004 - 19:23:02 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US