Received: from maia.hub.org (maia-3.hub.org [200.46.204.243]) by mail.postgresql.org (Postfix) with ESMTP id C7F7D1337B6E for ; Fri, 25 Feb 2011 12:15:24 -0400 (AST) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.243]) (amavisd-maia, port 10024) with ESMTP id 58466-09 for ; Fri, 25 Feb 2011 16:15:17 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from gw.wicourts.gov (gwmta.wicourts.gov [165.219.244.99]) by mail.postgresql.org (Postfix) with ESMTP id C68611337B43 for ; Fri, 25 Feb 2011 12:15:16 -0400 (AST) Received: from Courts-MTA by gw.wicourts.gov with Novell_GroupWise; Fri, 25 Feb 2011 10:15:15 -0600 Message-Id: <4D67812A020000250003B02D@gw.wicourts.gov> X-Mailer: Novell GroupWise Internet Agent 8.0.1 Date: Fri, 25 Feb 2011 10:15:06 -0600 From: "Kevin Grittner" To: ,, "'Tom Lane'" Subject: Re: LOCALTIMESTAMP has wrong time zone References: <000001cbd468$124cc720$36e65560$@com> <4D6681F1020000250003AFED@gw.wicourts.gov> <000a01cbd473$9f317fe0$dd947fa0$@com> <4D668E47020000250003AFF2@gw.wicourts.gov> <002801cbd4f7$a62bcc90$f28365b0$@com> In-Reply-To: <002801cbd4f7$a62bcc90$f28365b0$@com> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Content-Disposition: inline X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-4.21 tagged_above=-5 required=5 tests=BAYES_00=-1.9, RCVD_IN_DNSWL_MED=-2.3, T_RP_MATCHES_RCVD=-0.01 X-Spam-Level: X-Archive-Number: 201102/225 X-Sequence-Number: 29497 "Jonathan Brinkman" wrote: > ## I COULDN'T MAKE IT BREAK USING PSQL. That's pretty solid evidence that the problem isn't in the PostgreSQL server. > This didn't always happen, it just started happening on various of > my tables a maybe couple weeks or so ago. I think it is related to > an update, either to Ubuntu 10.04 or Postgresql 8.4. I usually > apt-get update/upgrade whenever I see that updates are available. I would look at /var/log/dpkg.log to see what you installed at the point when things broke. > Also, this only occurs on my production server (Rackspace cloud). > My dev postgres server doesn't do this timestamp time-zone problem > at all. I would be taking a close look at what the differences are. Anything that is the same on both servers can't be the problem, right? I'm going to harp on one other point -- you will almost certainly be better off if you make these columns TIMESTAMP WITH TIME ZONE. This is the type which is meant to represent moments in the stream of time. It will behave as you probably expect in many more circumstances, especially when recording when events occurred. WITHOUT TIME ZONE is mostly useful for scheduling future events which you want to happen at different points in time in different time zones, or for scheduling things which should occur in whatever time is in effect locally when the related date arrives. -Kevin