[SERVER-22193] Allow returning documents in the same order as $in Created: 15/Jan/16 Updated: 06/Dec/22 Resolved: 15/Jan/16 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Querying |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | NOVALUE Mitar | Assignee: | Backlog - Query Team (Inactive) |
| Resolution: | Duplicate | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||
| Assigned Teams: |
Query
|
||||||||
| Operating System: | ALL | ||||||||
| Participants: | |||||||||
| Description |
|
I often like to get documents which have IDs from an array of values using $in operator. But there is currently no way to get those documents in that same order. You have to retrieve them all to the client and sort them there. This is pretty inefficient. |
| Comments |
| Comment by NOVALUE Mitar [ 15/Jan/16 ] |
|
Ah, thanks. I searched for a duplicate but have not found it. |
| Comment by Stennie Steneker (Inactive) [ 15/Jan/16 ] |
|
Hi, There is already a feature suggestion for this .. please upvote/watch SERVER-7528: Order of responses to a MongoDB $in query. Thanks, |