Here is the scenario I am dealing with:
var temp = Collection.find({nom: "lol"}).fetch();
I made changes to the _id in this instance
Collection2.insert(temp);
After these operations, my MongoDB data looks like this:
{
"0" : {
_id: "65462984521651" //<- The updated id
//Additional information
//....
},
_id : "dvhssdhvflidsfjhv"
}
How can I insert the document into the root level instead of under "0"? Thank you for your help :)