Hello,
When there is a subquery in a plan, it looks like RelWriter always prints
the subquery without any indentation. Although this makes subquery
recognizable in most cases, I think it would become easier to read and look
better if we write the subquery with two more indentations than its rel,
and I think this format also corresponds to how we write code in Calcite.
Any thoughts about this? I added some example below.
This is the current representation of a plan with subquery:
LogicalProject("K0"=[$0], ...)
LogicalFilter(condition=[IN($4, {
LogicalProject(C0=[$5])
LogicalTableScan(table=[[CATALOG, STRUCT, T]])
})])
LogicalTableScan(table=[[CATALOG, STRUCT, T]])
After the change, it would look like this:
LogicalProject("K0"=[$0], ...)
LogicalFilter(condition=[IN($4, {
LogicalProject(C0=[$5])
LogicalTableScan(table=[[CATALOG, STRUCT, T]])
})])
LogicalTableScan(table=[[CATALOG, STRUCT, T]])
Best,
Juhwan
|