Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
APPLIES TO:
MongoDB vCore
The $eq
operator is used to match documents where the value of a field is equal to a specified value. This operator is particularly useful for filtering documents based on exact matches. It can be used in various query contexts, such as finding documents with specific field values, filtering arrays, and more.
Syntax
The syntax for the $eq
operator is as follows:
{ field: { $eq: value } }
Parameters
Description | |
---|---|
field |
The field to be compared. |
count |
The value to compare against. |
Related content
- Review options for Migrating from MongoDB to Azure Cosmos DB for MongoDB (vCore)
- Read more about Feature compatibility with MongoDB