[SERVER-13801] Query planner should allow assignment of range predicates to compound text index prefix keys Created: 30/Apr/14 Updated: 28/Dec/23 |
|
| Status: | Backlog |
| Project: | Core Server |
| Component/s: | Querying, Text Search |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Improvement | Priority: | Major - P3 |
| Reporter: | Will Shaver | Assignee: | Backlog - Query Integration |
| Resolution: | Unresolved | Votes: | 8 |
| Labels: | qi-text-search | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||
| Assigned Teams: |
Query Integration
|
||||
| Participants: | |||||
| Description |
|
On a schema like the following:
With an index like:
Doing this query succeeds as expected:
But this query fails:
|
| Comments |
| Comment by Adam Wamai Egesa [ 04/Apr/18 ] | |
|
As a user of the database API the limitation seems arbitrary while it really feels like the performance implications are really large for some implementations or forces us to change or database model quite a lot so definitely think the "Major - P3" priority label is well earned. That said, can we expect this to be prioritized for implementation soon? Or be given any estimation for what release this improvement will likely target? At this point I would assume it won't make it into the next coming major release, version 4.0. But maybe 4.2? | |
| Comment by Peter Sunde [ 09/Sep/15 ] | |
|
Will this feature be available in mongo 3.2 ? | |
| Comment by rohit lala [ 23/Apr/15 ] | |
|
Hi, any update on this JIRA ticket? | |
| Comment by Zack Carlson [ 31/Jul/14 ] | |
|
Is there a % likelyhood that the bounds generation predicates would be included in 2.7 (October?) | |
| Comment by J Rassi [ 01/May/14 ] | |
|
This is not currently supported; to use your index, queries must include an equality predicate on productId. Note the query error message "are equality predicates given for all prefix fields?" (see this page in the documentation for further info). Further work in this area will allow relaxing the equality predicate requirement, at which point any bounds-generating predicate would be able to substitute for it (e.g. $gt/$gte/$lt/$lte/$in/$type composed with $and/$or etc). Changing ticket type from "Bug" to "Improvement". | |
| Comment by Will Shaver [ 30/Apr/14 ] | |
|
This also fails with the same error:
| |
| Comment by Will Shaver [ 30/Apr/14 ] | |
|
And... I'd fix the formatting in my post but I can't edit now. |