Re: Timestamp Conversion Woes Redux

From: Dave Cramer <pg(at)fastcrypt(dot)com>
To: Kevin Grittner <Kevin(dot)Grittner(at)wicourts(dot)gov>
Cc: <pgsql-jdbc(at)postgresql(dot)org>
Subject: Re: Timestamp Conversion Woes Redux
Date: 2005-07-22 16:59:55
Message-ID: 23125128-B091-45E7-A6D0-9F2E5FAE97B1@fastcrypt.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc


On 22-Jul-05, at 12:30 PM, Kevin Grittner wrote:

> Argh! I've found some comments on this thread confusing, and I've
> discovered the source of this confusion -- I was thinking that a
> column
> defined as type "timestamp with time zone" would store a time zone
> with
> the timestamp. (Really, I did read the documentation on data
> types, but
> the discussion of how this data type is implemented slid right out
> of my
> head.) I will have to review everything with the actual
> implementation
> in mind; I now see why this is more complicated than I thought.
>
> Could someone confirm that a timestamp column in a PostgreSQL database
> never contains time zone data, regardless of whether or not the "with
> time zone" clause was used in its definition.
yes, that is correct.
> It seems to me that, if
> you ignore internals of how the data is stored (which an application
> programmer never need see), the only difference between "timestamp
> with
> time zone" and "timestamp without time zone" is whether a time zone
> specified in a literal will (a) be used to determine what moment the
> timestamp represents or (b) be ignored in favor of using the server's
> time zone to determine what moment the timestamp represents. In
> either
> case, the value returned when querying the column will be based on the
> server's time zone. Do I have that right?
That is my understanding yhest.
>
> -Kevin
>
>
>
> ---------------------------(end of
> broadcast)---------------------------
> TIP 3: Have you checked our extensive FAQ?
>
> http://www.postgresql.org/docs/faq
>
>

In response to

Browse pgsql-jdbc by date

  From Date Subject
Next Message Tom Lane 2005-07-22 17:03:13 Re: Timestamp Conversion Woes Redux
Previous Message Kevin Grittner 2005-07-22 16:30:12 Re: Timestamp Conversion Woes Redux