[SERVER-82204] Classic window functions first/last handle missing field incorrectly Created: 16/Oct/23 Updated: 30/Oct/23 Resolved: 26/Oct/23 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 7.1.1, 7.2.0-rc0, 6.0.12, 5.0.23, 7.0.4 |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Foteini Alvanaki | Assignee: | Rui Liu |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||||||||||||||
| Assigned Teams: |
Query Execution
|
||||||||||||||||||||||||
| Backwards Compatibility: | Minor Change | ||||||||||||||||||||||||
| Operating System: | ALL | ||||||||||||||||||||||||
| Backport Requested: |
v7.1, v7.0, v6.0, v5.0
|
||||||||||||||||||||||||
| Steps To Reproduce: | Dataset
Query :
Results
Expected Results
|
||||||||||||||||||||||||
| Participants: | |||||||||||||||||||||||||
| Description |
|
When the attribute tracked by first/last in the first/last document in the window has a missing attribute the functions return empty results. This is incorrect. According to the documentation they should return null to be consistent with the $group behaviour. |
| Comments |
| Comment by Githook User [ 26/Oct/23 ] |
|
Author: {'name': 'Rui Liu', 'email': 'lriuui0x0@gmail.com', 'username': 'lriuui0x0'}Message: (cherry picked from commit 26ba1c041a35f74a7ea7f3f436ab011db2599e38) |
| Comment by Githook User [ 26/Oct/23 ] |
|
Author: {'name': 'Rui Liu', 'email': 'lriuui0x0@gmail.com', 'username': 'lriuui0x0'}Message: (cherry picked from commit 26ba1c041a35f74a7ea7f3f436ab011db2599e38) |
| Comment by Githook User [ 26/Oct/23 ] |
|
Author: {'name': 'Rui Liu', 'email': 'lriuui0x0@gmail.com', 'username': 'lriuui0x0'}Message: (cherry picked from commit 26ba1c041a35f74a7ea7f3f436ab011db2599e38) |
| Comment by Githook User [ 26/Oct/23 ] |
|
Author: {'name': 'Rui Liu', 'email': 'lriuui0x0@gmail.com', 'username': 'lriuui0x0'}Message: (cherry picked from commit 26ba1c041a35f74a7ea7f3f436ab011db2599e38) |
| Comment by Githook User [ 25/Oct/23 ] |
|
Author: {'name': 'Rui Liu', 'email': 'lriuui0x0@gmail.com', 'username': 'lriuui0x0'}Message: |