pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Euler Taveira de Oliveira <euler@timbira.com>
Cc: Robert Haas <robertmhaas@gmail.com>
Cc: pratikchirania <pratik.chirania@hp.com>
Cc: pgsql-bugs@postgresql.org
Subject: Re: Timezone issues with Postrres
Date: Wed, 21 Sep 2011 16:31:51 -0400
Message-ID: <28648.1316637111@sss.pgh.pa.us> (raw)
In-Reply-To: <4E7A4570.9040609@timbira.com>
References: <1316149023380-4809498.post@n5.nabble.com>
	<4E7364B8.5070608@timbira.com>
	<1316589418035-4825401.post@n5.nabble.com>
	<CA+TgmobN-OFXRXpGCTi=e-sk2Lm+97As9B+bchWewjjLcohvzw@mail.gmail.com>
	<4E7A4570.9040609@timbira.com>

Euler Taveira de Oliveira <euler@timbira.com> writes:
> On 21-09-2011 13:38, Robert Haas wrote:
>> The rules for interpreting time zone specifications are arcane enough
>> to make me suspect that this isn't a bug even though it seems rather
>> odd, but in any case it would be useful to know how many hours
>> PostgreSQL's timestamp is behind (or ahead of) UTC and similarly for
>> the operating system.

> I think the OP is talking about one of these timezones:

It's a bit premature to speculate without knowing his exact timezone
setting, but there seem at least three possibilities:

1. The system clock is, in fact, set wrong, so that the OS is delivering
the wrong UTC time to Postgres.  This being on a Windows platform, I
wouldn't write that off.  It would be a good idea to do
	SET TIMEZONE = UTC;
and then see if now() reports the correct UTC time.

2. The timezone setting he's using is inappropriate for the jurisdiction
he's in, so that Postgres is following the wrong DST rule.  Not knowing
either his actual setting or his precise jurisdiction, this is hard to
guess about.

3. The zone data that Postgres has is obsolete for his zone.  This seems
entirely possible, although a look at the git logs doesn't reveal any
changes in Central American zone rules since 9.0.1 was released.  (I see
a change in Mexican rules listed for tzdata release 2010j in May 2010,
but that was in 9.0 beta2 and later.)  A relevant question here is
whether his jurisdiction has observed DST in recent years and then
changed their laws.

			regards, tom lane



view thread (12+ messages)  latest in thread

Message-ID: <28648.1316637111@sss.pgh.pa.us>
Permalink:  ../28648.1316637111@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/28648.1316637111@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-bugs@postgresql.org
  Cc: tgl@sss.pgh.pa.us, euler@timbira.com, robertmhaas@gmail.com, pratik.chirania@hp.com
  Subject: Re: Timezone issues with Postrres
  In-Reply-To: <28648.1316637111@sss.pgh.pa.us>
  References: <1316149023380-4809498.post@n5.nabble.com> <4E7364B8.5070608@timbira.com> <1316589418035-4825401.post@n5.nabble.com> <CA+TgmobN-OFXRXpGCTi=e-sk2Lm+97As9B+bchWewjjLcohvzw@mail.gmail.com> <4E7A4570.9040609@timbira.com> <28648.1316637111@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