Skip site navigation (1) Skip section navigation (2)

Re: Re: Bug in date_part()

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Thomas Lockhart <lockhart(at)alumni(dot)caltech(dot)edu>
Cc: phil(at)Stimpy(dot)netroedge(dot)com, pgsql-bugs(at)postgresql(dot)org
Subject: Re: Re: Bug in date_part()
Date: 2001-01-18 02:07:34
Message-ID: 22643.979783654@sss.pgh.pa.us (view raw or flat)
Thread:
Lists: pgsql-bugs
Thomas Lockhart <lockhart(at)alumni(dot)caltech(dot)edu> writes:
>> Query to reproduce the bug (7.0.3):
>> edge=# select date_part('dow','4/1/2001'::date)::int4;
>> ----------
>> 6

> I'm not seeing this on my 7.0.2 RPM installation, or on my from-cvs
> current sources (dow for April 1 comes up as zero, as you would expect).

I get the right answer from current sources, and the wrong one on 7.0.2.
It's ye olde date-to-timestamp-off-an-hour-at-DST-boundary problem.
Are you not running in a USA timezone?

			regards, tom lane

In response to

Responses

pgsql-bugs by date

Next:From: Thomas LockhartDate: 2001-01-18 03:43:15
Subject: Re: Bug in date_part()
Previous:From: Jason SchroederDate: 2001-01-18 00:28:17
Subject: regression failure: random

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group