Which command can be used to rebuild the indexes on a collection in MongoDB?
A. db.collection.createlndex({relndex:l})
B. db.collection.reIndex({author:l})
C. db.collection.relndexQ
D. db.collection.createIndex({author:l}).reIndex()
Which of the following is true about aggregation framework?
A. Each aggregation operator need to return atleast one of more documents as a result
B. the aggregate command operates on a multiple collection
C. A single aggregation framework operator can be used more than once in a query
D. Pipeline expressions are stateless except accumulator expressions used with $group operator
If you have created a compound index on (A,B, C) which of the following access pattern will not be able to utilize the index?
A. A, B, C
B. A
C. B, C
D. A, B
Mongodb does provide high availability via which option?
A. Replication
B. Indexing
C. Sharding
D. Journaling
In a sharded replicas set environment with multiple mongos servers, which of the following would decide the mongos failover?
A. mongos
B. mongo shell
C. individual language drivers
D. mongod
Consider the following posts document:
Which of the following queries will return the documents but with only the first two tags in the tags array?
A. db.posts.find({author:"Tom"?limit({tags:2})
B. db.posts.find({author:"Tom"?limit($slice:{tags:>;)
C. Both "db.posts.find({author:"Tom"},{tags:{$slice:2}})" and "db.posts.find({author:"Tom"}).limit($slice: {tags:2})" are valid. $slice works both with projection and limit.
D. db.posts.find({author:"Tom">,{tags:{$slice:2?
Which of the following collections stores authentication credentials in MongoDB?
A. test.users
B. local.users
C. system.users
D. users.users
Consider the following example document from the sample collection. All documents in this collection have the same schema.
Which of the following queries will replace this with the document.
A. db.sample.update( { "_id" : 3 } , { "$set" : { "_id" : 7 , "c" : 4 > > )
B. db.sample.update( { "_id" : 3 > , { "_id" : 7 , "c" : 4 > , { "justOne" : true > ) / This operation cannot be done with a single query.
C. db.sample.update( { "_id" : 3 > , { "_id" : 7 , "c" : 4 , { "$unset" : [ "a" , "b" ] } } )
D. db.sample.update( { "_id" : 3 > , { "_id" : 7 , "c" : 4 > )
Which mongodb tool is used to report details on number of database operations in MongoDB?
A. mongostat
B. mongotop
C. mongorestore
D. mongodump
Which of the following index would be optimum for the query?
Select all valid. db.test.find( { a : 5, c : 2 }) A. db.test.ensurelndex( { c:l, a: 1})
B. db.test.ensurelndex( { a : 1, c: 1, d: 1, b : 1})
C. CH db.test.ensurelndex( { a :1, c:l})
D. db.test.ensurelndex( { a: 1, b :1, c:l, d:l})
Consider the following documents:
You perform the following query;
How many documents will be updated by the query?
A. 0
B. 1
C. 2
D. 3
E. 5
'mongoimport' command is used for A. Batch data insertion
B. None of the above
C. Multiple command import
D. Multiple command insertion
Which format/standard is used by MongoDB internally to store documents?
A. JSON
B. BSON
C. B+ Trees
D. JSON - Extended
Aggregation Pipelines have a limit of:
A. No limit on document and 100 MB RAM
B. 2 MB document and no limit on RAM
C. 2 MB document and 100 MB RAM
D. 16 MB document and 100 MB RAM
What is the maximum size of Index Key Limit and Number of Indexes per collection?
A. 1024 bytes and 64 indexes
B. 12 mega bytes and 64 indexes
C. 64 bytes and 1024 indexes
D. 1024 bytes and unlimited indexes