Hi All, In order to test various cases of LATERAL join in Postgres-XC, I am trying to find a query where RelOptInof->lateral_relids would get set for plain base relations. I tried various examples like below. But none of them was able to set lateral_relids in RelOptInfo of the involved relations. I am using current master branch.
select * from tab1 left join lateral (select * from tab2 where tab2.val = tab1.val2) q using(val); This just pulled up the qual at higher level. select * from tab1 left join lateral (select sum(val2) sum_val2, val from tab2 where tab2.val2 = tab1.val2 group by tab2.val) q using(val); This at least caused the outer reference to be added as parameter, but again no lateral_relid. Is there an example query (however impractial query it would be), which can make the lateral_relids set in RelOptInfo of plain base relation? -- Best Wishes, Ashutosh Bapat EnterpriseDB Corporation The Postgres Database Company