Winter Sale Special Limited Time 65% Discount Offer - Ends in 0d 00h 00m 00s - Coupon code: v4s65

C100DBA Exam Dumps - MongoDB Certified DBA Associate Exam (Based on MongoDB 4.4)

Go to page:
Question # 9

Consider the following document from the products collection:

What does the following query using $elemMatch return? db.products.find( { product_code: "345678" }, { variations: { $elemMatch: { size: ^L^ } } } )

A.

Returns the complete document but retrieves only the size field from the array

B.

Returns the document but with only one element in the variations array (corresponding to size L)

C.

Returns the complete document since MongoDB does not support partial array retrieval

D.

Returns the complete document but retrieves only the size field from the array and also with only one element in the variations array (corresponding to size L)

Full Access
Question # 10

What does the following query do when performed on the posts collection? db.posts.update({_id:l},{Title:This is post with ID 1"})

A.

Syntax error

B.

Replaces the complete document with _id as 1 with the document specified in second parameter

C.

Updates the Title of the post

D.

Updating a document is possible only with $set

Full Access
Question # 11

In order to ensure that you can maintain high availability in the face of server failure, you should implement which of the following?

A.

Sharding

B.

Properly defined user roles

C.

Replication

D.

Put indexes on all of your documents

E.

The proper storage engine

Full Access
Question # 12

The MongoDB explain() method does not support which of the following verbosity mode:

A.

executionStats

B.

queryPlanner

C.

customExecutionStats

D.

allPlansExecution

Full Access
Question # 13

As per the aggregation pipeline optimization concepts, if you have a $sort followed by a $match:

A.

Providing these parameters in any order does not impact the performance

B.

$sort moves before $match

C.

MongoDB does not do any movements by default and will use the order provided

D.

$match moves before $sort

Full Access
Question # 14

In a replica set, a_________number of members ensures that the replica set is always able to select a primary.

A.

Even

B.

Odd

C.

2

D.

Depends on the application architecture

Full Access
Question # 15

What does the following aggregate query perform?

A.

Fetches the posts with likes between 100 and 200 and sets their _id as null

B.

Groups the posts by number of likes (101, 102, 103.) by adding 1 every time

C.

Calculates the number of posts with likes between 100 and 200

D.

Fetches the posts with likes between 100 and 200, sets the _id of the first document as null and then increments it 1 every time

Full Access
Question # 16

The difference between $push and $addToSet is:

A.

$addToSet needs the fields to be already present while $push will work even if the field is not present

B.

$addToSet adds the item to the field only if it does not exist already; while $push pushes the item to the field irrespective of whether it was present or not

C.

$addToSet adds the item to the field only if the new item is of the same datatype

D.

There is no major difference between them. $addToSet is a deprecated version of $push.

Full Access
Go to page: