Test case for [CALCITE-6882] RelMdColumnUniqueness incorrectly claims fields are not unique if constant refinement occurs in a node above join
Test case for [CALCITE-6882] RelMdColumnUniqueness incorrectly claims fields are not unique if constant refinement occurs in a node above join
If you comment out the first line of the method RelMdColumnUniqueness.areColumnsUnique(Filter, ...), the test passes. But all that line does is broaden columns from {0} to {0, 10}, which ordinarily should make areColumnsUnique more likely to return true.
The problem seems to be in areColumnsUnique(Join, ...), which will returns true for {0} (one column from the left side of the join) and false for a {0, 10} (one column from the each side of the join).
A few places in that method have 'if (columns.cardinality() > 0)', and I see no good reason why the empty set should be treated differently.
This pull request has been marked as stale due to 30 days of inactivity. It will be closed in 90 days if no further activity occurs. If you think that’s incorrect or this pull request requires a review, please simply write any comment. If closed, you can revive the PR at any time and @mention a reviewer or discuss it on the [email protected] list. Thank you for your contributions.
This pull request has been marked as stale due to 30 days of inactivity. It will be closed in 90 days if no further activity occurs. If you think that’s incorrect or this pull request requires a review, please simply write any comment. If closed, you can revive the PR at any time and @mention a reviewer or discuss it on the [email protected] list. Thank you for your contributions.