Free MongoDB C100DEV Exam Questions

Become MongoDB Certified with updated C100DEV exam questions and correct answers

Page:    1 / 83      
Total 411 Questions | Updated On: Nov 24, 2025
Add To Cart
Question 1

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
Question 2

You have a MongoDB collection named employees that contains documents with fields name, department, and salary. You want to update the salary of all employees in the "Marketing" department to $75,000. The original collection looks like this:
[
  { "_id": 1, "name": "Alice", "department": "Marketing", "salary": 60000 },
  { "_id": 2, "name": "Bob", "department": "Sales", "salary": 55000 },
  { "_id": 3, "name": "Charlie", "department": "Marketing", "salary": 62000 },
  { "_id": 4, "name": "David", "department": "Engineering", "salary": 70000 }
]
You run the following MongoDB update operation:
db.employees.updateMany(
  { "department": "Marketing" },
  { $set: { "salary": 75000 } }
)
What will the collection look like after this update operation?


Answer: C
Question 3

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 4

In a MongoDB collection named orders, you are tasked with retrieving a subset of documents that fulfill specific criteria. Each document in this collection contains the following fields: customerId, orderId, orderDate, and orderDetails (an embedded document with fields: product, quantity, unitPrice). You are required to fetch all orders made by the customer with a customerId of 1234 on a specific date 2023-04-12, and only return the orderId, orderDate, and product from orderDetails. Which of the following MongoDB queries would accurately fulfill these requirements?


Answer: A
Question 5

As a MongoDB Developer, you are tasked with optimizing a MongoDB database. Your collection has documents with the following structure:
{
  "_id": ObjectId(),
  "user_id": Number,
  "user_data": {
    "name": String,
    "email": String,
    "phone": String,
    "address": {
      "city": String,
      "state": String,
      "country": String
    }
  },
  "transactions": [
    {
      "transaction_id": Number,
      "amount": Number,
      "date": Date
    }
  ]
}
The application frequently queries for the total transaction amount for users based on the city. Which index should you create to optimize the performance of these queries?


Answer: B
Page:    1 / 83      
Total 411 Questions | Updated On: Nov 24, 2025
Add To Cart

© Copyrights DumpsCertify 2025. All Rights Reserved

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