Re: funkiness with '1999-12-31 19:00:00-05'::timestamp with time zone - Mailing list pgsql-general

From Tom Lane
Subject Re: funkiness with '1999-12-31 19:00:00-05'::timestamp with time zone
Date
Msg-id 28656.1283544071@sss.pgh.pa.us
Whole thread Raw
In response to Re: funkiness with '1999-12-31 19:00:00-05'::timestamp with time zone  (Josh Kupershmidt <schmiddy@gmail.com>)
Responses Re: funkiness with '1999-12-31 19:00:00-05'::timestamp with time zone
List pgsql-general
Josh Kupershmidt <schmiddy@gmail.com> writes:
> On Fri, Sep 3, 2010 at 3:40 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>> but I wonder what it was you actually did.

> I wonder myself :-) I encountered these timestamps while going through
> some C code I inherited which uses libpq to load several tables (such
> as myschema.strange_table in the original example) using COPY FROM
> STDIN. I don't think any timestamp arithmetic was involved. The code
> was supposed to copy in legitimate timestamps, but instead loaded all
> these '1999-12-31 19:00:00-05' values, and I'm still trying to figure
> out how/why.

Interesting.  I can't imagine how you could have produced these with
plain COPY, since that would go through timestamptzin.  Was it by any
chance a binary COPY?  If so I could believe that funny timestamps could
get in.  Maybe some confusion over endianness of the binary data, for
instance.

            regards, tom lane

pgsql-general by date:

Previous
From: Josh Kupershmidt
Date:
Subject: Re: funkiness with '1999-12-31 19:00:00-05'::timestamp with time zone
Next
From: Josh Kupershmidt
Date:
Subject: Re: funkiness with '1999-12-31 19:00:00-05'::timestamp with time zone