[SERVER-29585] Create a $_internalSchemaObjectMatch MatchExpression Created: 12/Jun/17 Updated: 30/Oct/23 Resolved: 11/Jul/17 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Querying |
| Affects Version/s: | None |
| Fix Version/s: | 3.5.10 |
| Type: | Task | Priority: | Major - P3 |
| Reporter: | Kyle Suarez | Assignee: | Nicholas Zolnierz |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Backwards Compatibility: | Fully Compatible |
| Sprint: | Query 2017-07-10, Query 2017-07-31 |
| Participants: |
| Description |
| Comments |
| Comment by Githook User [ 11/Jul/17 ] | ||
|
Author: {u'username': u'nzolnierzmdb', u'name': u'Nick Zolnierz', u'email': u'nicholas.zolnierz@mongodb.com'}Message: | ||
| Comment by Kyle Suarez [ 27/Jun/17 ] | ||
|
Reassigning this to Nick, as we're aggressively starting on the JSON Schema-to-MQL translation and require $objectMatch for many recursive object properties. | ||
| Comment by David Storch [ 22/Jun/17 ] | ||
|
A single match expression. You can always use $and or $or to meaningfully join a list of match expressions. | ||
| Comment by Kyle Suarez [ 22/Jun/17 ] | ||
|
Should it accept a single match expression, or a list of match expressions? | ||
| Comment by David Storch [ 22/Jun/17 ] | ||
|
Hmm, these were not my proposed semantics for $_internalSchemaObjectMatch. I was thinking that it would work like $elemMatch. It would accept a path and a nested match expression:
It would only match if "path.to.object" contains an element of BSONType::Object which also matches <MatchExpression>. So if you wanted to check that field nestedObj was an object containing at least 5 properties you could write this:
|