Free MongoDB C100DEV Exam Questions

Become MongoDB Certified with updated C100DEV exam questions and correct answers

Page:    1 / 83      
Total 411 Questions | Updated On: Jan 06, 2026
Add To Cart
Question 1

What is the correct syntax to insert multiple documents into a MongoDB collection named orders and return the _id values for all inserted documents?


Answer: B
Question 2

You are designing a MongoDB schema for an e-commerce platform. The platform has three main collections: Products, Orders, and Users.Products Collection: Contains information about each product, such as its name, price, and description.Orders Collection: Contains details about each order, including the userId (referencing the Users collection), an array of productIds (referencing the Products collection), and the total order amount.Users Collection: Contains user details, such as name, email, and address.Which of the following data modeling approaches represents an anti-pattern in MongoDB?


Answer: B
Question 3

As a MongoDB Developer, you are tasked with the deletion of specific documents in a collection named users. The documents to be deleted are those that meet the following criteria: the age field is less than 18 and the status field is "inactive". After the deletion, you need to know the count of the deleted documents. Which of the following commands would correctly perform this operation?


Answer: A
Question 4

You manage a MongoDB collection called inventory that stores documents for a store's inventory. Each document has the fields item, category, and quantity. You want to ensure that an item is always present in the collection, even if it needs to be inserted. Specifically, if the item "notebook" in the "Stationery" category does not exist, it should be inserted with a quantity of 50. If it does exist, its quantity should be updated to 50. You plan to use the following command:
db.inventory.updateOne(
  { "item": "notebook", "category": "Stationery" },
  { $set: { "quantity": 50 } },
  { upsert: true }
)
What will happen after executing this command if there is no "notebook" item in the "Stationery" category in the inventory collection?


Answer: D
Question 5

Consider a MongoDB collection named orders which has documents in the following format:
{
    "_id" : ObjectId("5f5b0d2f3e3dfbcc11c84444"),
    "orderId" : 1001,
    "customerId" : 200,
    "items" : [
        {
            "productId" : 101,
            "quantity" : 2
        },
        {
            "productId" : 102,
            "quantity" : 1
        }
    ],
    "totalAmount" : 250,
    "status" : "Pending"
}
What is the correct syntax to find and update the first document in the orders collection where "status" is "Pending", and change the "status" field to "Completed" using the findAndModify method?


Answer: B
Page:    1 / 83      
Total 411 Questions | Updated On: Jan 06, 2026
Add To Cart

© Copyrights DumpsCertify 2026. All Rights Reserved

We use cookies to ensure your best experience. So we hope you are happy to receive all cookies on the DumpsCertify.