[SERVER-11446] don't punt all not/nor to collscan. Created: 29/Oct/13  Updated: 11/Jul/16  Resolved: 04/Dec/13

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

Type: Bug Priority: Major - P3
Reporter: hari.khalsa@10gen.com Assignee: Benety Goh
Resolution: Done Votes: 0
Labels: query_triage
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Attachments: File server11446.js    
Issue Links:
Depends
is depended on by SERVER-10005 $exists:false prevents use of a spars... Closed
is depended on by SERVER-10608 {$exists: false} will not use index Closed
is depended on by SERVER-11821 Indexes are ignored with use of $not ... Closed
is depended on by SERVER-11839 index is not used to provide sort for... Closed
Related
Backwards Compatibility: Fully Compatible
Operating System: ALL
Participants:

 Description   

Currently we just output a collscan if we see a NOT/NOR. This is too conservative. We should just not descend down a not/nor when tagging the pred tree and go through planning as usual. Enumeration should stop if it sees a negation as well. This way we'll still affix a negation as a filter if there's an and-related pred that can use an index.



 Comments   
Comment by Githook User [ 04/Dec/13 ]

Author:

{u'username': u'benety', u'name': u'Benety Goh', u'email': u'benety@mongodb.com'}

Message: SERVER-11446 do not traverse into negation nodes when looking for indexable fields
Branch: master
https://github.com/mongodb/mongo/commit/0498f81e2553598862747392a4aa5a75a26807c0

Generated at Thu Feb 08 03:25:49 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.