Interview Questions & Answer for MongoDB

What are the advantages of MongoDB? Or in other words, why choosing MongoDB and not other implementation of NoSQL?

What is the difference between SQL and NoSQL?

In what scenarios would you prefer to use NoSQL/Mongo over SQL?

What is a document? What is a collection?

What is an aggregator?

What is better? Embedded documents or referenced?

Have you performed data retrieval optimizations in Mongo? If not, can you think about ways to optimize a slow data retrieval?

Queries

  • Explain this query: db.books.find({“name”: /abc/})
  • Explain this query: db.books.find().sort({x:1})
  • What is the difference between find() and find_one()?
  • How can you export data from Mongo DB?
Rajesh Kumar
Follow me