Articles → MONGODB → Comparison Operators In MongoDB
Comparison Operators In MongoDB
Comparison Operators
- $eq → checks if the values you are comparing are equal
- $ne → checks if the values you are comparing are not equal
- $lt → checks if the value 1 is less than value 2
- $gt → checks if the value 1 is greater than value 2
- $lte → checks if the value 1 is less than or equal to value 2
- $gte → checks if the value 1 is greater than or equal to value 2
Example