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

Multi $(update) use or update in aggregation pipeline

    • Type: Icon: Improvement Improvement
    • Resolution: Duplicate
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: Querying
    • None

      Why the positional $ operator cannot be used for queries which traverse more than one array?

      A possible solution is to pass to the update method an array of quey to solve $ operator.

      db.collection.update(

      { <array>: value ... }

      , { <update operator>:

      { "<array>.$....$" : value }

      },{ query_array:

      { query1,query2,...}

      } )
      Each item in array query solve in order the $ operator

            Assignee:
            Unassigned Unassigned
            Reporter:
            paulux Paolo Pino
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: