Hi Alena Rybakina For merge join + /* + * For now we do not support RIGHT_SEMI join in mergejoin. + */ + if (jointype == JOIN_RIGHT_SEMI) + { + *mergejoin_allowed = false; + return NIL; + } + Tanks
I have reviewed your patch and I think it is better to add an Assert for JOIN_RIGHT_SEMI to the ExecMergeJoin and ExecNestLoop functions to prevent the use of RIGHT_SEMI for these types of connections (NestedLoop and MergeJoin).
Hmm, I don't see why this is necessary. The planner should already guarantee that we won't have nestloops/mergejoins with right-semi joins.
Thanks Richard
--
Regards,
Alena Rybakina
Postgres Professional: http://www.postgrespro.com
The Russian Postgres Company