| From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
|---|---|
| To: | Merlin Moncure <mmoncure(at)gmail(dot)com> |
| Cc: | Andres Freund <andres(at)2ndquadrant(dot)com>, Shigeru Hanada <shigeru(dot)hanada(at)gmail(dot)com>, pgsql-hackers(at)postgresql(dot)org |
| Subject: | Re: Writable foreign tables: how to identify rows |
| Date: | 2013-03-13 15:35:13 |
| Message-ID: | 27035.1363188913@sss.pgh.pa.us |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
Merlin Moncure <mmoncure(at)gmail(dot)com> writes:
> As long as lock as held between ctid examination and row modification
> you are ok. didn't read the patch, just pointing that out (history is
> full of client side drivers that did not do this properly).
> I also might have missed some of the finer contextual points of the
> discussion here: I was thinking that you are identifying rows on the
> client over fetch transaction A to write back in transaction B. If
> that is the case, ctid based identification to me is full of issues
Absolutely --- you can't rely on ctid across transactions. postgres_fdw
isn't doing that though, just using it to update or delete rows that it
locked earlier in the same remote transaction.
regards, tom lane
| From | Date | Subject | |
|---|---|---|---|
| Next Message | David E. Wheeler | 2013-03-13 16:40:57 | Re: Duplicate JSON Object Keys |
| Previous Message | Merlin Moncure | 2013-03-13 15:24:21 | Re: Writable foreign tables: how to identify rows |