pg.ddx.io  pgsql-jdbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Kevin Grittner <Kevin.Grittner@wicourts.gov>
Cc: pg@fastcrypt.com
Cc: pgsql-jdbc@postgresql.org
Subject: Re: Timestamp Conversion Woes Redux
Date: Fri, 22 Jul 2005 14:27:00 -0400
Message-ID: <10316.1122056820@sss.pgh.pa.us> (raw)
In-Reply-To: <s2e0f2af.011@gwmta.wicourts.gov>
References: <s2e0f2af.011@gwmta.wicourts.gov>

"Kevin Grittner" <Kevin.Grittner@wicourts.gov> writes:
> What differences in _behavior_ are exposed to someone
> _using_ the database, other than ignoring time zone information for the
> "timestamp without time zone" values?

Well, other than the point that changing TimeZone changes the displayed
values of timestamptz but not timestamp, there's the fact that
timestamptz will reject (or change, actually) some values that timestamp
will consider valid.  For instance '2005-04-03 02:30' is valid to
timestamp, but in any US timezone it will come out as something
different in timestamptz.

regression=# show timezone;
 TimeZone
----------
 EST5EDT
(1 row)

regression=# select '2005-04-03 02:30'::timestamp;
      timestamp
---------------------
 2005-04-03 02:30:00
(1 row)

regression=# select '2005-04-03 02:30'::timestamptz;
      timestamptz
------------------------
 2005-04-03 03:30:00-04
(1 row)

			regards, tom lane



view thread (92+ messages)  latest in thread

Message-ID: <10316.1122056820@sss.pgh.pa.us>
Permalink:  ../10316.1122056820@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/10316.1122056820@sss.pgh.pa.us

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-jdbc@postgresql.org
  Cc: tgl@sss.pgh.pa.us, Kevin.Grittner@wicourts.gov, pg@fastcrypt.com
  Subject: Re: Timestamp Conversion Woes Redux
  In-Reply-To: <10316.1122056820@sss.pgh.pa.us>
  References: <s2e0f2af.011@gwmta.wicourts.gov> <10316.1122056820@sss.pgh.pa.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox