Uploaded image for project: 'Documentation'
  1. Documentation
  2. DOCS-13537

updateMany documentation is missleading

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Works as Designed
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: manual
    • Environment:

      Description

      Description

      Across different documentation updateMany differs:

      In: 

      https://github.com/mongodb/docs/blob/v4.2/source/tutorial/update-documents.txt

      https://github.com/mongodb/docs/blob/v4.2/source/reference/method/db.collection.updateMany.txt

       

      Somewherre is shown as:

       

      ```js 

      db.<collection>.updateMany({}, {$set: {a: 1);}}

      ```

      {{}}

      and somewhere as with brackets `[]`:

      {{}}

      ```js

      db.<collection>.updateMany({}, [ {$set: {a: 1 ]);}}

      {{}}

      Additionally, Mongoose documentation is missing about this command, and using the case without brackets silently changes no document.

      ```{{}}

      Scope of changes

      Impact to Other Docs

      MVP (Work and Date)

      Resources (Scope or Design Docs, Invision, etc.)

        Attachments

          Activity

            People

            Assignee:
            dave.cuthbert Dave Cuthbert
            Reporter:
            mprinc@gmail.com Sasha Rudan
            Participants:
            Last commenter:
            Jeffrey Allen Jeffrey Allen
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:
              Days since reply:
              41 weeks, 1 day ago
              Date of 1st Reply: