Re: why do we need two snapshots per query? - Mailing list pgsql-hackers

From Robert Haas
Subject Re: why do we need two snapshots per query?
Date
Msg-id CA+TgmoYpRvPoKw_WffUQCjugU+a_g7GVPaLSBxUb9xyMTxmVyQ@mail.gmail.com
Whole thread Raw
In response to Re: why do we need two snapshots per query?  (Dimitri Fontaine <dimitri@2ndQuadrant.fr>)
Responses Re: why do we need two snapshots per query?
List pgsql-hackers
On Sat, Nov 26, 2011 at 2:50 PM, Dimitri Fontaine
<dimitri@2ndquadrant.fr> wrote:
>> +     /* Done with the snapshot used for parameter I/O and parsing/planning */
>> +     if (snapshot_set)
>> +             PopActiveSnapshot();
>
> This comment needs adjusting.

I thought about adjusting it, but I didn't see what it made sense to
adjust it to.  It still is the parameter used for parameter I/O and
parsing/planning, so the existing text isn't wrong.  It will possibly
also get reused for execution, but the previous statement has a
lengthy comment on that, so it didn't seem worth recapitulating here.

> You need to be editing the comments for this function.  To be specific
> you didn't update this text:
>
>  * The caller can optionally pass a snapshot to be used; pass InvalidSnapshot
>  * for the normal behavior of setting a new snapshot.  This parameter is
>  * presently ignored for non-PORTAL_ONE_SELECT portals (it's only intended
>  * to be used for cursors).

Actually, I did, but the change was in the second patch file attached
to the same email, which maybe you missed?  Combined patch attached.

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

Attachment

pgsql-hackers by date:

Previous
From: Peter Eisentraut
Date:
Subject: Re: JSON for PG 9.2
Next
From: Peter Eisentraut
Date:
Subject: Re: JSON for PG 9.2