Consider that you have a collection called population which has fields state and city. Which of the following query will calculate the population grouped by state and city?
What command returns all documents in an orders collection where quantity is less than or equal to 1000 and salesRep is not equal to " Anne " ?
Which of the following needs to be performed prior to initiate backup on a sharded cluster?
Which command is used to determine storage capacity of specific database?
What encoded format does MongoDB store documents in?
What command lists all indexes for a collection?
Which TWO indicators should an administrator keep an eye on to determine if the storage capacity is nearing its limit?
In a collection that contains 100 post documents, what does the following command do? db. posts. find().skip(5).limit(5)
Which of the following commands finds all the documents in the posts collection with post timestamp field as null?
Which of the following is a valid insert statement in mongodb? Select all valid.
If the value of totalKeysExamined is 30000 and the value of totalDocsExamined is 0, which of the following option is correct?
Which of the documents below will be retrieved by the following query? Assume the documents are stored in a collection called " sample " . Check all that apply.
db.sample.find( { " $or " : [ { " a " : { " $in " : [ 3, 10] > }, { " b " : { " $lt " : 2 > > ] > )
JSON stands for
A MongoDB database administrator is asked to add the privilege find to a role named myRole.
What is the correct syntax for adding this privilege to the role in MongoDB?
Which of the following is supported by MongoDB?
What is a limitation of encryption at rest?
The Production MongoDB Cluster contains Personally Identifiable Information, such as Name, Demographics, Date of Birth, and Government Identification Number. Due to strict compliance requirements, a database administrator is tasked to ensure a client ' s side encryption.
What feature should the administrator use to meet the requirement?
Which of the following is correct about MongoDB?
In which of the following scenarios is sharding not the correct option. Select all that apply.
Which is the default mode in which the explain() command runs?
What method should be used to configure dynamically runtime parameters for the mongod process in MongoDB?
Which of the following is a valid Replica Set configuration if you want:
1-Have 3 copies of everything
2- That RS3 is never primary
2- That RSI and RS2 can be primary?
You had to see the different configurations, RS3 could be hidden or priority 0 (But not a referee because we need
3 replicas), while RSI and RS2 could NOT have priority 0 or be hidden or anything like that
In a 4-member RS RSO , RSI, RS2 and RS3 + Referee, RSO (primary) falls after some write operations that have
replicated RSI and RS2 (but NOT RS3), who can get up as the new primary?
The configuration comes and in it we see that RS2 has a hidden: true (or a priority: 0, (I don ' t remember)
You are comparing values of different BSON types in mongodb. You want to compare from lowest to highest. Which comparison order is used?
What does the output x of the following MongoDB aggregation query result into; db.posts.aggregate( [ { $group: { _id; " $author " , x: { $sum: $likes } } } ] )
A MongoDB collection named users contains sample documents with fields including name, age, address, description, city, and occupation.
The administrator uses the following query to perform a collection scan:
db.users.find({ city: " New York " , occupation: " Software Engineer " })
What compound index will improve the performance of the query the MOST?
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.
Which of the following are valid json documents? Select all that apply.
Which node in a replica set does accept write operation?
What feature is one of the differences between using MongoDB and a relational database management system (RDBMS) database?
What command is used to grant a role " customRole1 " to an existing user called " user1 " ?
As per the aggregation pipeline optimization concepts, if you have a $sort followed by a $match:
In a replica set, a_________number of members ensures that the replica set is always able to select a primary.
To add a new user and enable authentication in MongoDB, which of the following steps need be executed?
What is one purpose of a hidden index?
Which format/standard is used by MongoDB internally to store documents?
What is the output of following two commands in MongoDB: db. posts. insert({n_id " :l}) db.posts.insert({ " _id " :l})
Which of the following operator can be used to control the number of items of an array that a query returns?
What is the output of the following program?
A MongoDB database administrator needs to improve the performance of the following query:
db.employees.find(
{},
{ name: 1, department: 0, salary: 1 }
).sort({ department: 1, salary: -1 });
What index should the administrator use to achieve this goal?
What stage of the Winning Plan in an Explain Result identifies the Index Key for the query pattern?
Mongodb does provide high availability via which option?
A department store maintains a clothing collection:
{ " _id " : 1, " item " : " sweater " , " sizes " : [ " XS " , " S " , " L " ] }
{ " _id " : 2, " item " : " t-shirt " , " sizes " : [ " S " , " M " , " L " ] }
{ " _id " : 3, " item " : " vest " , " sizes " : [ " M " , " L " , " XL " , " XXL " ] }
An employee runs:
db.clothing.find( { " sizes " : " M " } )
Which index should improve performance for this query the MOST?
What is the replication factor for a replicated cluster with 1 primary, 3 secondaries with one of them hidden. The set also has an arbiter?
What does the following query do when performed on the posts collection? db.posts.update({_id:l},{Title:This is post with ID 1 " })
Which of the following is true of the mechanics of replication in MongoDB? Check all that apply.
Which of the following does MongoDB use to provide High Scalability?
What are the audit log destinations? (Select three)
Addding the index {a:l} can potentially decrease the speed of which of the following operations? Check all that apply.
In a sharded replica set environment, the w Option provides ability for write concern and j Option provides ability for the data to be written on disk journal. Consider that we have a seven member replica set and we want to assure that the writes are committed to journal. What should be the value of j?
A user stores movie data in a collection called movies. The collection contains thousands of documents.
A sample document looks like this:
{ " title " : " Titanic " , " year " : 1997, " rating " : 8.6 }
The user runs the following query to sort movies first by year, and then by rating:
db.movies.find().sort({ " year " : 1, " rating " : -1 })
Which index would improve the query ' s performance the MOST?
Given the following query:
db.load.find({
_id: { $lte: 1000 },
rnd: 1234,
date: { $gte: ISODate( " 2023-01-01 " ) }
}).sort({ date: -1 })
In a compound index that best supports this query, what field should be first field?