Allow compound wildcard indexes to provide index bounds for $and query

XMLWordPrintableJSON

    • Type: Improvement
    • Resolution: Fixed
    • Priority: Major - P3
    • 7.0.0-rc5
    • Affects Version/s: None
    • Component/s: None
    • None
    • Query Optimization
    • Fully Compatible
    • v7.0
    • QO 2023-06-12, QO 2023-06-26
    • 154
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      SERVER-75545 imposed a rule that overkills the usage of a compound wildcard index with regular prefix field, especially for $and query. This rule should only apply to $or queries because it’s still a correctness issue that an expanded CWI answering $or query could cause missing documents. The CWI should still be able to provide a bounded plan for $and queries, for example, one very common case - a CWI {a:1, “sub.$**”: 1} should answer both point and range queries like {a:1, “sub.a”: 1}, {a: {$gt: 1}, “sub.c”: {$gt: 1}}.

            Assignee:
            Ruoxin Xu
            Reporter:
            Ruoxin Xu
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved: