Work at SourceForge, help us to make it a better place! We have an immediate need for a Support Technician in our San Francisco or Denver office.

Close

#26 Incorrect handling of TIMESTAMP columns

open
nobody
None
5
2006-10-24
2006-10-24
Dave Cole
No

The 2.5.1 module incorrectly applies the timezone
offset to TIMESTAMP columns. I get correct results
querying TIMESTAMP columns using pqsl but pyPgSQL seems
to be double applying the timezone offset.

The attached patch Works For Me (TM) by only doing the
localtime() conversion for TIMESTAMP WITH TIME ZONE
columns.

Discussion

  • Dave Cole
    Dave Cole
    2006-10-24

    Fix localtime conversion for TIMESTAMP columns

     
    Attachments
  • Dave Cole
    Dave Cole
    2006-10-24

    Logged In: YES
    user_id=28658

    And here is the small test program I used to see the before
    and after behaviour.

    $ python test-timestamp DATABASE-NAME

     
  • Dave Cole
    Dave Cole
    2006-10-24

    test program

     
    Attachments