MongoDB Certified DBA Associate (C100DBA) — Question 3

Which two commands project the “product” and “_id” fields? (Choose two.)

Answer options

Correct answer: B, C

Explanation

Option B is correct because it specifies both 'product' and '_id' fields for projection. Option C is also correct since it uses the project method to include the same fields. Options A and D are incorrect as they only project the 'product' field, thereby omitting the '_id' field.