From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Bruno Wolff III <bruno(at)wolff(dot)to> |
Cc: | TJ <tj(at)nospam(dot)com>, pgsql-general(at)postgresql(dot)org |
Subject: | Re: database design with timestamp |
Date: | 2002-11-07 18:12:13 |
Message-ID: | 23399.1036692733@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Bruno Wolff III <bruno(at)wolff(dot)to> writes:
> On Tue, Nov 05, 2002 at 20:03:37 +0000,
> TJ <tj(at)nospam(dot)com> wrote:
>> I think I need to somehow display these timestamps back into their timezone
>> of origin...so as to be more intuitive for the managers.
> You can use SET TIME ZONE in a session to change the time zone used for
> outputting time.
BTW, a lot of people don't realize at first that PG's notion of
timekeeping is similar to the Unix model: it's all UTC under the hood,
and timezones are just syntactic sugar for input and output.
IMHO this makes it a lot easier to do databases that will be used by
people in multiple timezones: the stored data is really UTC, but each
person can enter times in his own zone, and will see times displayed
in his own zone (where "your own zone" means "whatever you've currently
got TimeZone set to").
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Bruce Momjian | 2002-11-07 18:42:57 | Re: PostgreSQL on Linux and Solaris comparison |
Previous Message | Neil Conway | 2002-11-07 18:07:28 | Re: Encrypted Database? |