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

Add full path to implicitly traversed field in MatchDetails

    • Type: Icon: Improvement Improvement
    • Resolution: Won't Fix
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: Querying
    • Labels:
      None
    • Query 2018-11-19, Query 2018-12-03

      From the scope document:

      In cases where we traverse an array en route to a field referenced by the match expression, the path to that field should also (optionally) be returned.

      The PoC for this provides the path to the first field after the traversal (the "elem match key"), although we may want to prefer an approach that provides the path all the way to the matching element.

      For reference the PoC branch (available here on GitHub) includes a rough implementation of this functionality. The relevant changes are in match_details.cpp, match_details.h, matcher/path.cpp, matcher/path.h, and expression_path.h

      Optionally, we could augment FieldRef as part of this work so that it specifically distinguishes array index path components regular fields.

            Assignee:
            jacob.evans@mongodb.com Jacob Evans
            Reporter:
            justin.seyster@mongodb.com Justin Seyster
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: