Search Postgresql Archives

Re: Timestamp vs timestamptz

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



But watch out! This is mentioned in the docs but it bit me when I used timestamp with time zone so:

timestamp with time zone does not record the timezone you inserted it with- it simply stores the GMT version and converts to whatever timezone you like on demand. If the timezone is important data, you will need an extra column for it. For example, flight arrival information should probably include the timezone of the destination.

-M

On Jul 13, 2006, at 8:04 PM, David Fetter wrote:

On Thu, Jul 13, 2006 at 04:35:20PM -0700, Antimon wrote:
Hi,
I'm working on a web project with pgsql, i did use mysql before and
stored epoch in database so i'm not familiar with these datatypes.

What i wanna ask is, if i don't need to display timestamps in
different timezones,

Not this week, but who knows about next week?

shall i use timestamptz anyway?

Yes.  Timestamptz is the one. :)

¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬
AgentM
agentm@xxxxxxxxxxxxxxxxxxxxx
¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬ ¬



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux