Answers for "push in mongodb inner array"

0

mongodb push element in nested array

db.collection.update(
    { "_id": ID, "playlists._id": "58"},
    { "$push": 
        {"playlists.$.musics": 
            {
                "name": "test name",
                "duration": "4.00"
            }
        }
    }
)
Posted by: Guest on January-20-2021
-2

how to push array in mongodb

pushing to mongodb
Posted by: Guest on October-08-2021

Browse Popular Code Answers by Language