[SERVER-633] test performance of and optimize $in Created: 12/Feb/10  Updated: 06/Dec/22  Resolved: 19/May/17

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

Type: Improvement Priority: Minor - P4
Reporter: Eliot Horowitz (Inactive) Assignee: Backlog - Query Team (Inactive)
Resolution: Won't Fix Votes: 5
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Assigned Teams:
Query
Participants:

 Comments   
Comment by David Storch [ 19/May/17 ]

One thing we would like to do in this area is treat $or and $in identically in the query engine, ensuring that we can create the same quality plans for these logically equivalent operators and that both execute efficiently. However, this ticket is quite general, so we are closing it as "Won't Fix". Many improvements and changes to the query engine have been made in the seven years or so since this was filed.

Comment by Tianon Gravi [ 10/Mar/11 ]

Does this include optimizing cases of an empty $in list and a list with a single item? In our testing, $in with an empty list (in a "count" query, no less) was extremely slow. Does it scan the index whether there's anything in the list or not? It seems like it ought to just see the empty list and assume no matches, since you can't match nothing, no matter how hard you search.

Generated at Thu Feb 08 02:54:43 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.