Re: Timestamp with time zone - Mailing list pgsql-novice

From Xavier Robin
Subject Re: Timestamp with time zone
Date
Msg-id 4C2B59BF.4040008@bluewin.ch
Whole thread Raw
In response to Re: Timestamp with time zone  (Tim Landscheidt <tim@tim-landscheidt.de>)
List pgsql-novice
(copy to the list)
Le 30.06.2010 16:25, Tim Landscheidt a écrit :
> So if you need the timezone information, you'll have to re-
> cord it separately.

Oh, I was thinking about that, but it sounded weird because it was what
I was expecting from a TIMESTAMP WITH*OUT* TIME ZONE column.

Just one more question to make sure I got it all right:

EXTRACT(timezone FROM <a timestamptz here>)

will *always* return 0? Because the doc suggests that positive or
negative values can be returned…
And (just 1 more) so what's the point of this field in the first place?


>   IMVHO best practice is to treat TIMESTAMP WITH TIME ZONE
> as truly evil (TM), only use UTC timestamps in the database
> and only convert them from and to something timezonic in
> your application when it has to interact with a human being.

I'll try to keep that in mind!

Thanks,
Xavier


Attachment

pgsql-novice by date:

Previous
From: Michael Glaesemann
Date:
Subject: Re: Timestamp with time zone
Next
From: Tim Landscheidt
Date:
Subject: Re: Timestamp with time zone