Re: Incorrect handling of timezones with extract

From: Josh Berkus <josh(at)agliodbs(dot)com>
To: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Incorrect handling of timezones with extract
Date: 2013-03-12 17:36:18
Message-ID: 513F6792.3020907@agliodbs.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers


> and extract(day) from that gives -2 not -3. You could argue that this
> definition of timestamp subtraction isn't too consistent with the
> timestamp-plus-interval operator, and you'd be right; but I doubt we'd
> consider changing it now.

We specifically added that feature to support production calendaring
applications; I worked on it with Karel. When someone calendars a event
to be "3 days later" they don't expect it to jump by an hour because it
crossed a DST boundary. So changing it would break a bunch of people's
apps, especially mine.

--
Josh Berkus
PostgreSQL Experts Inc.
http://pgexperts.com

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Daniel Farina 2013-03-12 17:40:51 Re: postgres_fdw vs data formatting GUCs (was Re: [v9.3] writable foreign tables)
Previous Message Tom Lane 2013-03-12 17:09:06 Re: Incorrect handling of timezones with extract