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

RE: Indexing LDAP entries



Title: RE: Indexing LDAP entries

Your guesses are right. It seems that the filters are named appropriately after all :)

Most of the following is not OpenLDAP-specific. You should read more about the protocol.

An equality filter allows you look for entries that exactly match some value, e.g. (cn=Jatin Nansi)
A substring filter is the name for a filter containing wildcards, e.g. (givenName=J*n) or (sn=*an*) etc
Presence filters match any entry that has at least one value for the attribute, e.g. (cn=*)
Approximate filters do things like sounds like, and the implementation is vendor and language-specific (e.g. French doesn't sound like English). I don't know what algorithms OpenLDAP uses to locate entries.

You can specify just "sub" but I bet it's more expensive to maintain than one of the subsets. If all searches will be for filters like (sn=Nan*), then clearly you don't care about a wildcard at the beginning, right? So I wouldn't bother to support it. You can always reindex later as usage dictates.

Also, see my stupid mistake http://www.openldap.org/lists/openldap-software/200109/msg00225.html

-----Original Message-----
From: Jatin Nansi [mailto:jatin.nansi@timesgroup.com]
Sent: Tuesday, February 26, 2002 12:34 PM
To: oberwetter, josh
Cc: 'openldap-software@openldap.org'
Subject: Re: Indexing LDAP entries


Hi josh,

Thanks for the reply.

I now understand index type sub and its family of indexes.
But I am still very unclear about the other types, here is
what I think they are and their usage, please correct me
where I am wrong:

eq : maintain an index for exact matches. so I suppose
it is only used if the filter pattern does not use wildcards.

pres : maintain an index for presence of attributes for any
entry?

approx : approximate index, what is it, how will it be used,
and for what sort of search filters?

sub : consists of subinitial, subany, subfinal. Can i just specify
"sub" as an index type, or does it have to be 1 of the above?

Regards

Jatin

On Tuesday 26 February 2002 22:08, oberwetter, josh wrote:
> This question has been asked & answered before. See the mailing list
> archives & the FAQ.
>
> For example
> http://www.openldap.org/lists/openldap-software/200202/msg00231.html
> http://www.openldap.org/faq/data/cache/42.html
> and http://www.openldap.org/faq/data/cache/190.html
>
> -----Original Message-----
> From: Jatin Nansi [mailto:jatin.nansi@timesgroup.com]
> Sent: Tuesday, February 26, 2002 11:44 AM
> To: 'openldap-software@openldap.org'
> Subject: Indexing LDAP entries
>
>
> Hi,
>
> I understand that adding indexing information to the ldap database
> will make lookups several times faster. But I do not understand exactly
> what does pres,eq,approx,sub,none mean.
>
> Is there anywhere i can find out the meanings of these terms and when
> to use these?
>
> Thanks
>
> Jatin