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

Revert changes to positional projections and positional updates in 3.4

    XMLWordPrintable

Details

    • Task
    • Status: Closed
    • Major - P3
    • Resolution: Fixed
    • None
    • 3.4.0-rc4, 3.5.1
    • Querying
    • None
    • Fully Compatible
    • Query 2016-11-21

    Description

      SERVER-14662 changed positional projections and positional updates to error if multiple arrays were encountered when matching the filter. This change had undesirable effects. Users were no longer able to issue the following positional projections and positional updates:

      > db.c.insert({a: [1, 2], b: [3, 4]})
      > db.c.find({a: 1, b: 4}, {"a.$": 1})
      

      > db.c.insert({a: [1, 2], b: [3, 4]})
      > db.c.update({a: 1, b: 4}, {$set: {"a.$": 5}})
      

      We will no longer error in these cases.

      Attachments

        Issue Links

          Activity

            People

              tess.avitabile@mongodb.com Tess Avitabile (Inactive)
              tess.avitabile@mongodb.com Tess Avitabile (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: