-
Type: New Feature
-
Resolution: Duplicate
-
Priority: Major - P3
-
None
-
Affects Version/s: None
-
Component/s: Aggregation Framework
-
Query
Aggregation framework could be a powerful way to transform one shape of document schema into another if values could be turned into keys and vice versa.
Example schema:
{ userId: "xxx", attributeName: "yyy", attributeValue: "zzz"}could be projected into
{ userId: "xxx", "yyy": "zzz"}for a subset of attribute names where now we can do simple $match for our criteria.
Conversely, ability to turn keys into values would allow aggregation based on existence of certain keys.
It would also allow aggregating by key rather than by value.
- duplicates
-
SERVER-18794 Add an aggregation expression to convert an object to an array of key, value pairs
- Closed
-
SERVER-23310 Add an expression to convert an array of pairs to an object
- Closed
- is duplicated by
-
SERVER-6429 $unwind keys in a document or subdocument and group by them without knowing all the field names beforehand.
- Closed
- is related to
-
SERVER-11392 $unwind on subdocuments
- Closed
- related to
-
SERVER-8582 Extend document expression language in aggregation to support advanced document filtering.
- Closed
-
SERVER-13928 Iteration over Map support
- Closed