Query. All ("name", "A", "B"); // matches an array with multiple elements.
Query. And (query. eq ("name", "A"), query. eq ("title", "T"); // satisfy multiple conditions at the same time
Query. eq ("name", "A"); // equal
Query. exists ("type", true); // checks whether the key value exists.
Query. gt ("value", 2); // greater than>
Query. GTE ("value", 3); // greater than or equal to> =
Query. In ("name", "A", "B"); // includes all specified values. You can specify different types of conditions and values.
Query. LT ("value", 9); // less than <
Query. Lte ("value", 8); // less than or equal to <=
Query. Mod ("value", 3, 1); // divide the query value by the first given value. If the remainder is equal to the second given value, this result is returned.
Query. Ne ("name", "C"); // not equal
Query. Nor (array); // does not include values in the array
Query. Not ("name"); // element Condition Statement
Query. notin ("name", "A", 2); // returns a document that does not match all the conditions in the array.
Query. Or (query. eq ("name", "A"), query. eq ("title", "T"); // meets one of the conditions
Query. Size ("name", 2); // specify the length of the key.
Query. Type ("_ id", bsontype. objectid); // type of the given key
Query. Where (bsonjavascript); // execute JavaScript
Query. Matches ("title", STR); // fuzzy query is equivalent to like -- STR in SQL that can contain regular expressions.