[Date Prev][Date Next] [Chronological] [Thread] [Top]

RE: Indexed searches which contain a NOT filter return incomplete results (ITS#1405)



Kurt, 

Thanks for the response. Yes, I see (sorry, I missed your point before). 

I guess that my fix is an attempt to strengthen the "pres" index to be "exact", rather than just "candidate". An "exact" index can be used for NOT filters.

It seems possible to promote equality indices to be "exact" in a similar way - although quite a major code change, I imagine. Substring indices, on the other hand, are "candidate" by their very nature.

Perhaps it's worth adding a new utility "IsThisIndexExact(indextype)" and associated code changes, so that: 
- "pres" indices can be made "exact" now (so used for NOT filters) 
- substring indices can be made "inexact" now (so never used for NOT filters) 
- "eq" indices can be inexact for now, but perhaps upgraded to "exact" another day 

Charlie 


-----Original Message----- 
From: Kurt D. Zeilenga [<mailto:Kurt@OpenLDAP.org>mailto:Kurt@OpenLDAP.org] 
Sent: 25 October 2001 18:06 
To: Charlie Bodycote 
Cc: openldap-its@OpenLDAP.org 
Subject: RE: Indexed searches which contain a NOT filter return 
incomplete results (ITS#1405) 

Indices return candidate lists for a filter component 
which may contain entries which do not the filter component. 
Hence, the 'not' of the candidate list may not contain all 
of the entries which do match the not of the filter component. 
The error is to assume otherwise. 

Your test attempts to improve the pres index (and as such 
may be worthy of inclusion), but it clearly doesn't address 
the underlying design issue regarding index application and 
the not operator. 

At 08:43 AM 2001-10-25, Charlie Bodycote wrote: 
>Is this really acceptable? 

Well, as you argue, it's not acceptable to have only a 
subset of the matched entries returned. 

Kurt