Re: What are ExecSeqMarkPos and ExecSeqRestrPos used for - Mailing list pgsql-general

From Stephen Frost
Subject Re: What are ExecSeqMarkPos and ExecSeqRestrPos used for
Date
Msg-id 20130528133248.GC8597@tamriel.snowman.net
Whole thread Raw
In response to What are ExecSeqMarkPos and ExecSeqRestrPos used for  (DT <kurt023@hotmail.com>)
Responses Re: What are ExecSeqMarkPos and ExecSeqRestrPos used for
List pgsql-general
* DT (kurt023@hotmail.com) wrote:
>   I'm reading code of nodeSeqscan, and was confused with ExecSeqMarkPos and
> ExecSeqRestrPos. They are only called by ExecMergeJoin. Could merge join use
> a plain seqscan as outer/inner plan? If not, what are they used for?

ExecSeqMarkPos and ExecSeqRestPos are called through execAmi.c's
generalized ExecMarkPos and ExecRestrPos, which are then used by both
nodeMergejoin.c and nodeResult.c.  Offhand, it seems unlikely that there
would ever be a path from MergeJoin down to ExecSeqMarkPos as MergeJoin
requires sorted inputs.  Perhaps it could happen with a full cartesian
product but I don't know that we'd ever use a MergeJoin to implement
that or that we have such an optimization today.

    Thanks,

        Stephen

Attachment

pgsql-general by date:

Previous
From: Moshe Jacobson
Date:
Subject: Re: search_path for database vs user vs session
Next
From: image
Date:
Subject: Restore a pgsql base from openERP v5(ubuntu) to v7(windows7)