[SERVER-1824] Support for inserting into specific array index Created: 21/Sep/10  Updated: 06/Apr/23  Resolved: 30/Aug/12

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: New Feature Priority: Major - P3
Reporter: Les Hill Assignee: Unassigned
Resolution: Duplicate Votes: 9
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Any


Issue Links:
Duplicate
duplicates SERVER-2363 $push/$pushAll support for insertion ... Closed
Related
related to SERVER-1014 A modifier to delete a single value f... Closed
Participants:

 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']}

 Comments   
Comment by Scott Hernandez (Inactive) [ 30/Aug/12 ]

dup of server-2363, which covers more.

Comment by Artem [ 30/Aug/12 ]

+1 Please realize this feature!

Comment by Scott Lowe [ 16/Aug/12 ]

+1 Would be extremely helpful to me.

Comment by Andrew Harrison [ 07/Jul/11 ]

Seems to go hand in hand with SERVER-1014 ( https://jira.mongodb.org/browse/SERVER-1014 ). Hoping that you manage to figure out a way to implement these!

Comment by Eliot Horowitz (Inactive) [ 22/Sep/10 ]

Possible - syntax is tricky to get right.
Will track demand for scheduling

Generated at Thu Feb 08 02:58:09 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.