Articles → MONGODB → $Not Operator In Mongodb$Not Operator In MongodbIn this article, we will discuss the $not operator in MongoDB.Purpose The $not operator is used to perform logical negation.Example Consider the following example: -To perform the not operator, we will use the following query: -db.sales.find({product: { $not: { $eq: "A"} }})Output Posted By - Karan Gupta Posted On - Friday, March 1, 2024 Query/Feedback Your Email Id** Subject* Query/Feedback Characters remaining 250**
db.sales.find({product: { $not: { $eq: "A"} }})
Query/Feedback