Re: BUG #5191: now() returns same value from Perl. - Mailing list pgsql-bugs

From Tom Lane
Subject Re: BUG #5191: now() returns same value from Perl.
Date
Msg-id 6268.1258404863@sss.pgh.pa.us
Whole thread Raw
In response to BUG #5191: now() returns same value from Perl.  ("Clark Pearson" <cloink_friggson@ntlworld.com>)
List pgsql-bugs
"Clark Pearson" <cloink_friggson@ntlworld.com> writes:
> If I 'SELECT now()' repeatedly from a perl script connected to the database
> via DBD::Pg, the returned value does not get updated to the new system
> time.

This is the correct behavior if you're inside the same transaction all
along, which is to be expected if you set autocommit off and then don't
issue any commits.  now() is defined as transaction start time.

            regards, tom lane

pgsql-bugs by date:

Previous
From: Robert Haas
Date:
Subject: Re: BUG #5191: now() returns same value from Perl.
Next
From: Tom Lane
Date:
Subject: Re: BUG #5192: --disable-integer-datetimes changes timestamp comparison behavior