Include sort index plans for rooted $or queries with CBR

    • Type: Improvement
    • Resolution: Unresolved
    • Priority: Blocker - P1
    • None
    • Affects Version/s: None
    • Component/s: None
    • None
    • Query Optimization
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      The analysis of SERVER-108140 shows that currently CBR does not consider plans using potential sort index for the entire query. The sort index is considered only for each individual subquery and then discarded during plan tagging, since we don't allow whole index scans for $or branches..

      See for example query q0063 from the synthetic benchmark.

      Adding these plans to the enumerated space and choosing between them and the best subquery plan can solve this problem.

            Assignee:
            Unassigned
            Reporter:
            Milena Ivanova
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated: