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

search not commutative on |



why can't i switch search items in a filter with an or function 
e.g.
ldapsearch   -v   '(&(|(gidNumber=15000)(gidNumber=15500))(uid=kdeblonde))'
ldap_init( <default>, 0 )
filter pattern: (&(|(gidNumber=15000)(gidNumber=15500))(uid=kdeblonde))
returning: ALL
filter is: ((&(|(gidNumber=15000)(gidNumber=15500))(uid=kdeblonde)))
uid=kdeblonde,ou=dekempen,ou=people,dc=bla,dc=bla
objectClass=top
objectClass=person
objectClass=organizationalPerson
objectClass=inetOrgPerson
objectClass=posixAccount
objectClass=inetLocalMailRecipient
objectClass=shadowAccount
objectClass=sambaAccount
sn=Koen Deblonde
uidNumber=15501
gidNumber=15500
objectClass=top
...
1 match


but 
ldapsearch   -v   '(&(|(gidNumber=15500)(gidNumber=15000))(uid=kdeblonde))'
ldap_init( <default>, 0 )
filter pattern: (&(|(gidNumber=15500)(gidNumber=15000))(uid=kdeblonde))
returning: ALL
filter is: ((&(|(gidNumber=15500)(gidNumber=15000))(uid=kdeblonde)))
0 matches


jef