fdb-record-layer icon indicating copy to clipboard operation
fdb-record-layer copied to clipboard

DOT renderer sometimes renders repeated subgraphs more than once

Open hatyo opened this issue 6 months ago • 0 comments

Here is an example of a self-join query that reuses the TypeFilter twice (because it scans the same table twice):

select * from t1 as x, t1 as y

When rendering the RelationalExpression with the group references, it does exactly what we expect:

image

However, when rendering without the group references, i.e. calling:

https://github.com/FoundationDB/fdb-record-layer/blob/ee43d69b4baf6334a4c337ea60ea4286a60e7462/fdb-record-layer-core/src/main/java/com/apple/foundationdb/record/query/plan/cascades/expressions/RelationalExpression.java#L812

with false argument, we get:

image

This is somewhat confusing considering that we use the same logical type filter, however it is still rendered twice.

hatyo avatar Aug 15 '24 15:08 hatyo