[SERVER-41346] all accumulators should be available as expressions Created: 28/May/19  Updated: 06/Dec/22  Resolved: 14/Apr/20

Status: Closed
Project: Core Server
Component/s: Aggregation Framework
Affects Version/s: None
Fix Version/s: None

Type: New Feature Priority: Major - P3
Reporter: Asya Kamsky Assignee: Backlog - Query Team (Inactive)
Resolution: Duplicate Votes: 0
Labels: expression, pm1457-nominee
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Duplicate
duplicates SERVER-44327 Add $first and $last expressions Closed
Related
related to SERVER-15697 Create a string accumulator for aggre... Backlog
Assigned Teams:
Query
Participants:

 Description   

Not clear why $first $last and $addToSet are the only accumulators not available as regular expressions with array argument.  In particular $last is helpful to avoid very verbose syntax for $arrayElemAt plus calculate position of last element ($subtract 1 from $size)



 Comments   
Comment by Asya Kamsky [ 14/Apr/20 ]

$fiirst and $last were done under SERVER-44327. Should this ticket be repurposed to track $addToSet not being available as an expression (it can be worked around via $setUnion though).

Comment by Craig Homa [ 17/Jun/19 ]

ted.tuckman@mongodb.com to consider this as part of the work that george.wangensteen will be doing.

Generated at Thu Feb 08 04:57:28 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.