Re: problem with bytea and undecorated literals
Karsten Hilbert <[email protected]> Tue, 4 May 2010 09:13:53 +0200
| Newsgroups | gmane.comp.python.db.psycopg.devel |
|---|---|
| Message-ID | <[email protected]> |
On Tue, May 04, 2010 at 03:02:23AM +0100, Daniele Varrazzo wrote:
> >>> cur.execute("select '2010-05-04T02:27:11+08:00'::timestamptz")
> >>> cur.fetchone()[0].isoformat()
> '2010-05-03T19:27:11+01:00' # should have been 08:00
'2010-05-03T19:27:11+01:00'
'2010-05-04T02:27:11+08:00'
19 + (8-1) = 26
26 - 24 = 2
Could this be PostgreSQL converting the
'2010-05-04T02:27:11+08:00'
to UTC on the way in and giving it back to you as
'2010-05-03T19:27:11+01:00'
on the way out due to the testing client's timezone
being set to "+1" ?
Karsten
--
GPG key ID E4071346 @ wwwkeys.pgp.net
E167 67FD A291 2BEA 73BD 4537 78B9 A9F9 E407 1346