opt: eliminate unnecessary IndexJoins that wrap partial index scans #54588
Labels
C-performance
Perf of queries or internals. Solution not expected to change functional behavior.
T-sql-queries
SQL Queries Team
Projects
There are numerous cases where an unnecessary IndexJoin wraps a partial index scan. This happens when proving filter/predicate implication reduces the remaining filters such that a column that is not stored in the partial index is no longer referenced after the scan.
#53586 fixed this when the unnecessary IndexJoin was wrapped in a Project. However, there are other cases that this fix does not cover. Here is one example:
Ideally, normalization rules could be run that would prune the unnecessary
s
column from the IndexJoin, and ultimately remove the IndexJoin altogether.Jira issue: CRDB-3736
The text was updated successfully, but these errors were encountered: