These patches fix all my known failure cases (attached.) In addition, as a plus, a small set of queries that previously didn't compile are now accepted, for example:
SELECT coalesce(u1.id + 1, 1) AS o0 FROM (u AS u1 FULL JOIN (u AS u2 JOIN u AS u3 ON u2.id = u3.id) ON u2.id = u2.id) GROUP BY 1;
... previously gave ERROR: FULL JOIN is only supported with merge-joinable or hash-joinable join conditions
now returns 10 rows (`2 … 11`), which I believe is correct.
``` HashAggregate Group Key: COALESCE((u1.id + 1), 1) -> Merge Full Join -> Seq Scan on u u1 -> Materialize -> Seq Scan on u u3 ```