Red Hat Directory Server 8.0 Administrator's Guide

NOTE
An LDAPv3 search is required to perform internationalized searches. Therefore,
do not specify the -V2 option on the call for ldapsearch.
This section focuses on the matching rule filter portion of the ldapsearch syntax. For more
information on general ldapsearch syntax, see Section 3, “LDAP Search Filters”. For
information on searching internationalized directories using the Users and Groups portion of
the Red Hat Console, see the online help.
This section covers the following topics:
Section 4.1, “Matching Rule Filter Syntax”
Section 4.2, “Supported Search Types”
Section 4.3, “International Search Examples”
4.1. Matching Rule Filter Syntax
A matching rule provides special guidelines for how the directory compares strings during a
search operation. In an international search, the matching rule tells the system what collation
order and operator to use when performing the search operation. For example, a matching rule
in an international search might tell the server to search for attribute values that come at or after
llama in the Spanish collation order. The syntax of the matching rule filter is as follows:
attr:matchingRule:=value
attr is an attribute belonging to entries being searched, such as cn or mail.
matchingRule is a string that identifies either the collation order or the collation order and a
relational operator, depending on the preferred format. For a discussion of matching rule
formats, see Section 4.1.1, “Matching Rule Formats”.
value is either the attribute value to search for or a relational operator plus the attribute value
to search for. The syntax of the value portion of the filter depends on the matching rule format
used.
4.1.1. Matching Rule Formats
The matching rule portion of a search filter can be represented in any several ways, and which
one should be used is a matter of preference:
Appendix B. Finding Directory Entries
564