LDAP : The LDAP Players : LDAP search : Search Specification

Search Specification
The search filter string excludes instances of LdapEntry that do not match the string. At its simplest a filter is attribute operator value. Operator can test
For instance, ‘(roomNumber>9000)’ matches instances of LdapEntry whose roomNumber is greater than 9000. Value can contain wild cards. Use '(objectClass=*)' if you want to match everything.
Filters can be componded
Anded: (&(filter1)(filter2)) e.g: '(&(ou=Peons)(sn=S*))'
Ored: (|(filter1)(filter2)) e.g. '(|(cn=V*)(sn=X*))'
Negated: (!(filter)) e.g. '(!(sn=Mair))'
See EsLdapExamples class>> exampleFilter* for examples.
Warning:
Spaces in filter strings will cause them to fail. (See EsLdapExamples class >> exampleFilterUsingAndFail.)
The search base string sets the place to start the search in the LDAP directory hierarchy. Setting it to the DN ou=Payroll,dc=example,dc=com will cause the search to start at the organizationalUnit Payroll level.
The scope determines how far down from the base the search will look in the directory hierarchy. Scope is one of
LDAP_SCOPE_SUBTREE is the scope default for a new instance of LdapSearch (LdapSearch new).