Re: strange timezone problem

From: andy <andy(at)squeakycode(dot)net>
To: Nick Johnson <ctfdy(at)spatula(dot)net>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: strange timezone problem
Date: 2007-11-07 17:17:17
Message-ID: 4731F31D.2070404@squeakycode.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Nick Johnson wrote:
> Before I open a bug on this, I wanted to do a sanity check, since there
> may be something I'm just not seeing.
>
> I'm using PostgreSQL 8.2.3 and seeing this behaviour with timezones:
>
> select create_date from article_lead;
> create_date
> ---------------------------
> 2007-11-04 16:35:33.17+00
> 2007-11-04 04:35:36.09+00
> 2007-11-05 04:35:36.38+00
> 2007-11-05 16:35:36.67+00
> (4 rows)

Note the top two are not in order (cuz you didnt 'order by create_date')

>
> select create_date from article_lead where create_date >= '2007-11-03
> 17:00:00.0' and create_date <='2007-11-04 16:00:00.0';
> create_date
> ---------------------------
> 2007-11-04 04:35:36.09+00

This one is correct, it is the second row. And the first row should not
be in because its > 16:00.

The db looks correct to me.

-Andy

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Nick Johnson 2007-11-07 17:24:51 Re: strange timezone problem
Previous Message Tom Lane 2007-11-07 17:16:42 Re: strange timezone problem