From: Tom Lane <tgl@sss.pgh.pa.us>
To: Michael Glaesemann <grzm@seespotcode.net>
Cc: Stuart Brooks <stuartb@cat.co.za>
Cc: pgsql-sql@postgresql.org
Subject: Re: TIMESTAMP comparison problem
Date: Tue, 22 Jan 2008 12:13:33 -0500
Message-ID: <3623.1201022013@sss.pgh.pa.us> (raw)
In-Reply-To: <794E6600-42A8-41A2-822D-080E19F9F0CC@seespotcode.net>
References: <4795A3B0.3010505@cat.co.za>
<794E6600-42A8-41A2-822D-080E19F9F0CC@seespotcode.net>
Michael Glaesemann <grzm@seespotcode.net> writes:
> Well, you can't get better than microsecond precision with timestamps
> in Postgres. And the only way you can rely on that level of precision
> is to compile with --enable-integer-datetimes.
There is more precision in there, but the output routine won't show it
to you. I think the real issue in Stuart's example is that what's being
shown as .746349 is actually .7463494 or something like that. Doing an
extract(epoch) on the stored values might be instructive.
If you don't want to deal with these sorts of issues then yeah, you want
integer timestamps.
regards, tom lane
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-sql@postgresql.org
Cc: tgl@sss.pgh.pa.us, grzm@seespotcode.net, stuartb@cat.co.za
Subject: Re: TIMESTAMP comparison problem
In-Reply-To: <3623.1201022013@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox