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

Support for inserting into specific array index

    Details

    • Type: New Feature
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Duplicate
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None
    • Environment:
      Any

      Description

      Hi guys,

      Would a $insert_at operator for an array be possible? Something like:

      given a document:

      { a : [ 'one', 'three' ] }

      the update: { $insert_at : { a :

      { 1 : 'two' }

      }}

      results in:

      { a : ['one', 'two', 'three']}

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                9 Vote for this issue
                Watchers:
                6 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: