Complete the code to project only the 'name' field from the 'users' collection.
db.users.find({}, { [1]: 1 })The projection specifies which fields to include. Here, we include only the 'name' field.
Complete the code to exclude the '_id' field from the results.
db.products.find({}, { [1]: 0 })Setting '_id' to 0 excludes it from the returned documents.
Fix the error in the projection to include only 'title' and 'author' fields.
db.books.find({}, { title: 1, [1]: 1, _id: 0 })To include 'author' along with 'title', set 'author' to 1 in the projection.
Fill both blanks to project 'username' and exclude '_id' in the query.
db.accounts.find({}, { [1]: 1, [2]: 0 })Set 'username' to 1 to include it, and '_id' to 0 to exclude it.
Fill all three blanks to project 'firstName', 'lastName', and exclude '_id' in the query.
db.employees.find({}, { [1]: 1, [2]: 1, [3]: 0 })Include 'firstName' and 'lastName' by setting them to 1, and exclude '_id' by setting it to 0.