Re: Add support for printing/reading MergeAction nodes - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Add support for printing/reading MergeAction nodes
Date
Msg-id 18333.1522858774@sss.pgh.pa.us
Whole thread Raw
In response to Add support for printing/reading MergeAction nodes  (Marina Polyakova <m.polyakova@postgrespro.ru>)
Responses Re: Add support for printing/reading MergeAction nodes
Re: Add support for printing/reading MergeAction nodes
Re: Add support for printing/reading MergeAction nodes
List pgsql-hackers
Marina Polyakova <m.polyakova@postgrespro.ru> writes:
> When debugging is enabled for server logging, isolation tests fail 
> because there're no corresponding output functions for InsertStmt / 
> DeleteStmt / UpdateStmt that are used in the output of the MergeAction 
> nodes (see the attached regressions diffs and output). I also attached a 
> try that makes the tests pass. Sorry if I missed that it was already 
> discussed somewhere.

Uh ... what?

Those node types are supposed to appear in raw grammar output only;
they should never survive past parse analysis.

If the MERGE patch has broken this, I'm going to push back on that
and push back on it hard, because it probably means there are a
whole bunch of other raw-grammar-output-only node types that can
now get past the parser stage as well, as children of these nodes.
The answer to that is not to add a ton of new infrastructure, it's
"you did MERGE wrong".

BTW, poking around in the grammar, I notice that MergeStmt did not
get added to RuleActionStmt.  That seems like a rather serious
omission.

            regards, tom lane


pgsql-hackers by date:

Previous
From: Jesper Pedersen
Date:
Subject: Re: [HACKERS] path toward faster partition pruning
Next
From: Tomas Vondra
Date:
Subject: Re: [HACKERS] logical decoding of two-phase transactions