Re: BUG #5031: DATE_TRUNC returns the wrong value when specifying MONTH - Mailing list pgsql-bugs

From Tom Lane
Subject Re: BUG #5031: DATE_TRUNC returns the wrong value when specifying MONTH
Date
Msg-id 8377.1251955467@sss.pgh.pa.us
Whole thread Raw
In response to BUG #5031: DATE_TRUNC returns the wrong value when specifying MONTH  ("Mark Douglas" <mark@steelhousemedia.com>)
Responses Re: BUG #5031: DATE_TRUNC returns the wrong value when specifying MONTH  (Mark Douglas <mark@steelhousemedia.com>)
List pgsql-bugs
Mark Douglas <mark@steelhousemedia.com> writes:
> I have my timezone set to GMT so there really shouldn't be any time zone adjustments.

Okay ...

postgres=# set timezone = GMT;
SET
postgres=# SELECT DATE_TRUNC('MONTH', CURRENT_DATE);
       date_trunc
------------------------
 2009-09-01 00:00:00+00
(1 row)

I suspect there's something you're not telling us, like you're
using a client-side library that is doing timezone adjustments
behind your back.

            regards, tom lane

pgsql-bugs by date:

Previous
From: Tom Lane
Date:
Subject: Re: BUG #5031: DATE_TRUNC returns the wrong value when specifying MONTH
Next
From: Keith Cascio
Date:
Subject: Re: BUG #5032: unexpected syntax error for plpgsql function returns table