MongoDB TutorialLesson 3Free preview
MongoDB Query API
This lesson is part of MongoDB · All levels
Summary
This lesson explains the MongoDB Query API, which is how to filter, select, and manipulate data through query documents. You're going to put together an object-like filter that describes the condition you're looking for, and then combine it with operators like $gt and $and. This API is used both by mongosh and by drivers in the application.
Key points
- Query is an object that describes the condition of a document matching
- The query operator starts with the dollar, for example $gt, $in, $and, and $or
- Query API is used in mongosh at once in all MongoDB drivers
- Filters can be combined for complex criteria in one search.
Full lesson
Code examples and quizzes
Full lessons, code examples, and quizzes are available to subscribers. 5 questions.