diff --git a/docs/gates.md b/docs/gates.md index c57a26d..d199188 100644 --- a/docs/gates.md +++ b/docs/gates.md @@ -1,14 +1,17 @@ -#### Search and return only certain fields +**Search and return only certain fields** -Search by regular expression (use the slash or quote marks as a delimiter). -@{"name": {$regex: /^M.*/}} +**Search by regular expression (use the slash or quote marks as a delimiter). +**@{$name: {$regex: /^M.*/}} -Case insensitive: -@{"name": {$regex: /^jan.*/, $options: "i"}} +**Case insensitive: +**@{$name: {$regex: /^jan.*/, $options: "i"}} -Find by elements in array -This matches documents that contain all of these array elements: -@{"skills": {$all: }} +**Find by elements in array +**This matches documents that contain all of these array elements: +@{$skills: {$all: }} -Match on any element in the array: -@{"skills": "negotiation"} +**Match on any element in the array: +**@{$skills: "negotiation"} + +**Match on inequality +@{ $strength: { $gt: 18 } }