How to Insert Multiple Documents using One Line in Mongoose
Автор: Azhar Techno Coder
Загружено: 2022-09-17
Просмотров: 465
Описание:
How to Insert Multiple Documents using One Line in Mongoose
Code:
//create or Insert document
const insertDoc = async() = {
try{
const vbscriptPlaylist = new ChannelPlaylist({
nameOfChannel : "Azhar Techno Coder",
noOFVideos : 43,
author : "Azhar",
active : true
})
const javascriptPlaylist = new ChannelPlaylist({
nameOfChannel : "Azhar Techno Coder",
noOFVideos : 84,
author : "Azhar",
active : true
})
const mongoDbPlaylist = new ChannelPlaylist({
nameOfChannel : "Azhar Techno Coder",
noOFVideos : 10,
author : "Azhar",
active : true
})
const doc = await ChannelPlaylist.insertMany([vbscriptPlaylist,mongoDbPlaylist,javascriptPlaylist])
console.log(doc)
}catch(err){
console.log(err)
}
}
insertDoc();
Chapters:
0:00 - Introduction to the video
0:33 - Procedure for Inserting Multiple Documents using One Line in Mongoose
3:32 - End Tags and subscription to the channel
My second Channel:
WrestleTalkByAzhar - / wrestletalkbyazhar
Next Steps :
---------------------------------------------------------------------------------------------------------------------------------------------------------
---------------------------------------------------------------------------------------------------------------------------------------------------------
Must Watch Playlists
► 1. Javascript - • Javascript Factory
► 2. Puppetter - • Puppeteer
► 3. Cypress - • Cypress
► 4. Tech works - • Видео
► 5. Vbscript Basics To Advanced - • VBScript Part 1 - Features Advantages Dis...
► 6. Jmeter - • Jmeter Tutorials
► 7. Excel - • Videos On Excel
► 8. Appium - • Appium
► 9. Shares - • Shares
► 10. Javascript Interview Questions - • Javascript Interview Questions
► 11. C# Tutorials - • C# Factory
► 12. HTML & CSS - • HTML & CSS
► 13. Browser Console - • Browser Console
► 14. JSON - • Videos on Json
► 15. Specflow - • Specflow Tutorials
► 16. MongoDB - • MongoDB Tutorials
---------------------------------------------------------------------------------------------------------------------------------------------------------
---------------------------------------------------------------------------------------------------------------------------------------------------------
#mongodb
#mongodbtutorial
#mongodbtutorialforbeginners
Повторяем попытку...
Доступные форматы для скачивания:
Скачать видео
-
Информация по загрузке: