On Tue, Sep 29, 2015 at 4:49 AM, Kouhei Kaigai <kai...@ak.jp.nec.com> wrote:
> Also note that EvalPlanQualFetchRowMarks() will raise an error
> if RefetchForeignRow callback returned NULL tuple.
> Is it right or expected behavior?

That's not how I read the code.  If RefetchForeignRow returns NULL, we
just ignore the row and continue on to the next one:

            if (copyTuple == NULL)
            {
                /* couldn't get the lock, so skip this row */
                goto lnext;
            }

And that seems exactly right: RefetchForeignRow needs to test that the
tuple is still present on the remote side, and that any remote quals
are matched.  If either of those is false, it can return NULL.

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


-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

Reply via email to