[SERVER-23310] Add an expression to convert an array of pairs to an object Created: 23/Mar/16 Updated: 19/Jul/17 Resolved: 07/Mar/17 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Aggregation Framework |
| Affects Version/s: | None |
| Fix Version/s: | 3.4.4, 3.5.5 |
| Type: | New Feature | Priority: | Major - P3 |
| Reporter: | Charlie Swanson | Assignee: | Tess Avitabile (Inactive) |
| Resolution: | Done | Votes: | 6 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||||||||||||||||||||||||||||||||||
| Backwards Compatibility: | Fully Compatible | ||||||||||||||||||||||||||||||||||||||||||||
| Backport Requested: |
v3.4
|
||||||||||||||||||||||||||||||||||||||||||||
| Sprint: | Query 2017-03-27 | ||||||||||||||||||||||||||||||||||||||||||||
| Participants: | |||||||||||||||||||||||||||||||||||||||||||||
| Description |
|
In many cases, it would be useful to construct an object from an array of key/value pairs. The new expression should be designed to work with the expression requested in
The expression should accept an array of pairs either represented as
In the latter case, the expression would permit conversion of [{k: "price", v: 200}, {k: "item", v: "mango"}] to {price: 200, item: "mango"}. |
| Comments |
| Comment by Githook User [ 28/Mar/17 ] |
|
Author: {u'username': u'sindbach', u'name': u'Wan Bachtiar', u'email': u'sindbach@gmail.com'}Message: Signed-off-by: Tess Avitabile <tess.avitabile@mongodb.com> |
| Comment by Githook User [ 07/Mar/17 ] |
|
Author: {u'username': u'sindbach', u'name': u'Wan Bachtiar', u'email': u'sindbach@gmail.com'}Message: Signed-off-by: Tess Avitabile <tess.avitabile@mongodb.com> |