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

POC: New positional path syntax in agg: "a.$[0]"

    • Type: Icon: Task Task
    • Resolution: Won't Fix
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • None
    • Query 2019-03-25

      At a first guess, there are three main pieces to this work:

      1. Adding logic to the FieldPath class to notice and accept something like "$[0]".
      2. Adding logic to the Document and Value classes to interpret this correctly in methods like 'getDottedPath'
      3. Adding logic to the $project and $addFields stages to support something like {$addFields: {"a.$[0]": 1}} - $project might be slightly weirder with its semantics of how anything not referenced is not included.

            Assignee:
            justin.seyster@mongodb.com Justin Seyster
            Reporter:
            charlie.swanson@mongodb.com Charlie Swanson
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: