Common ldap queries, Common ldap queries 42 – Google Apps Directory Sync Administration Guide User Manual

Page 42

Advertising
background image

42

Release 4.0.2

For examples of how these operators are used, see the common LDAP queries
below.

Common LDAP Queries

The examples below show the most common LDAP queries. These queries are
the most common queries used, and are designed to work with most directory
server environments.

All objects (this may cause load problems):

objectclass=*

All user objects that are designated as a “person”

(&(objectclass=user)(objectcategory=person))

Mailing Lists only

(objectcategory=group)

Public Folders only

(objectcategory=publicfolder)

All user objects except for ones with primary email addresses that begin with
“test”

(&(&(objectclass=user)(objectcategory=person))(!(mail=test*)))

All user objects except for ones with primary email addresses that end with
“test”

(&(&(objectclass=user)(objectcategory=person))(!(mail=*test)))

Any

*

Wildcard to represent that a field can equal
anything except NULL.

Parentheses

()

Separates filters to allow other logical
operators to function.

And

&

Joins filters together. All conditions in the
series must be true.

Or

|

Joins filters together. At least one condition in
the series must be true.

Not

!

Excludes all objects that match the filter.

Name of
Operator

Character

Use

Advertising