Labour Day Sale Limited Time 70% Discount Offer - Ends in 0d 00h 00m 00s - Coupon code: scxmas70

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

Question # 4

Consider that our posts collection contains an array field called tags that contains tags that the user enters. {

Which of the following commands will find all the posts that have been tagged as tutorial.

A.

db.posts.find( { tags : ["tutorial"] } );

B.

db.posts.find( { $array : {tags: "tutorial") > );

C.

db.posts.find( { tags : "tutorial" } );

D.

db.posts.findInArray( { tags : "tutorial" > );

Full Access
Question # 5

Which option should be used to update all the documents with the specified condition in the MongoDB query?

A.

specify {all: true} as the third parameter of update command

B.

updateAII instead of update

C.

specify {updateAII: true} as the third parameter of update command

D.

specify {multi : true} as the third parameter of update command

Full Access
Question # 6

What read preference should your application use if you want to read from the primary under normal circumstances but allow reads from secondaries when a primary is unavailable?

A.

secondaryPreferred

B.

Secondary

C.

nearest

D.

primary

E.

primaryPreferred

Full Access
Question # 7

In what format does mongodump creates backup files?

A.

BSON

B.

JSON

C.

SOAP

D.

XML

Full Access
Question # 8

Which of the following is incorrect statement about find and findOne operations in MongoDB?

A.

findQ returns all the documents in a collection while findOne() retrieves only the first one.

B.

find.limit(l) is not the same query as findOne()

C.

findOneQ returns the actual first document retrieved from a collection

D.

findQ and findOneQ returns cursors to the collection documents

Full Access
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
Question # 17

Aggregation Pipelines have a limit of:

A.

2 MB document and 100 MB RAM

B.

16 MB document and 100 MB RAM

C.

No limit on document and 100 MB RAM

D.

2 MB document and no limit on RAM

Full Access
Question # 18

In a collection that contains 100 post documents, what does the following command do? db. posts. find().skip(5).limit(5)

A.

Skip and limit nullify each other. Hence returning the first five documents.

B.

Skips the first five documents and returns the next five

C.

Limits the first five documents and then return them in reverse order

D.

Skips the first five documents and returns the sixth document five times

Full Access
Question # 19

Which operations add new documents to a collection?

A.

Create

B.

update

C.

insert

D.

delete

Full Access