From: Kingsley <kr...@kr...> - 2007-06-21 06:13:21
|
Hi-ho, I'm using PyPgSQL against a table that has a 'timestamp' type field. Under Linux I have no problems, but when results are returned from the database under win32, they are shifted by +10 hours (This is also happens to be my timezone.) I have not applied a timezone to the timestamp-type field. Interestingly, they are being stored correctly, just not retrieved properly. The times in the database are indeed stored in UTC, but PyPgSQL doesn't know this ;) Any suggestions as to why this should happen only under Windows? How about hints on how to fix it? I could always kludge in an: timestamp - interval '-36000 seconds' Type fix, but that's very dodgey. (even if the timeshift is from time.timezone) The timezone is set under windows, as it is under Linux. (GMT+10 / Sydney, NSW) I'm using "pyPgSQL-pre2.5-20050926.win32-py2.4.exe" as the latest version crashes my (py2exe) exe, during "import pyPgSQL". thanks, -kt |