Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-74186

Support query on non-wildcard prefix fields with compound wildcard indexes

    • Type: Icon: Task Task
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 7.0.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • Fully Compatible
    • QO 2023-03-06

      A compound wildcard index(CWI), {a: 1, b: 1, "sub.$**": 1, c: 1}, should be able to use on queries on only the non-wildcard prefix of this index, e.g. query: {a: 1, b: 1}.

      This requires:

      1. CWI can generate index keys for document w/o any wildcard field, e.g. {a: 1, b: 1}
      2. Wildcard expanding should expand a wildcard index entry to an IndexEntry even though no wildcard field is in the query.
      3. Fields after such wildcard field should not support non-blocking sort. (In the example above, field 'c' cannot support non-blocking sort)

            Assignee:
            ruoxin.xu@mongodb.com Ruoxin Xu
            Reporter:
            ruoxin.xu@mongodb.com Ruoxin Xu
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: