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

ldap filter order



Hello,
I have 

10 000 objects with attributeA=john

and

100 of these objects has also attributeB=mary

both attributes are indexed.

Does it make any difference between 

(&(attributeA=john)(attributeB=mary))

vs.

(&(attributeB=mary)(attributeA=john))

I bet it is better to exclude john-matched objects
from the set of 100 mary-matched objects, than
exclude 100 mary-matched objects from the set
of 10 000 john-matched objects, is that right?

In other words - does it make sens to order complicated
filters to match possible low-volume results from the left,
and high-volume sets on the right? 
This, of course, apply to AND filters only.

Regards,
DT

-- 
http://dtpw.pl/buell [ 25th anniversary of Buell - American Motorcycles ]
Linux aleft 2.6.27.29-0.1_lustre.1.8.1.1-default #1 SMP
drbd version: 8.3.7 (api:88/proto:86-91)
pacemaker 1.0.6-cebe2b6ff49b36b29a3bd7ada1c4701c7470febe