Christian Marg wrote:
Hello,
Howard Chu wrote:
> In OpenLDAP you would set an equality index on uidNumber and do a query
> for, e.g., (uidNumber<=2147483647) with sizelimit=1.
Sounds like an intriguing way to find the highest uidNumber, but
Sorry I misspoke, I was thinking of something else. We talked about ordered
indexing for integers but only actually implemented it for generalizedTime and
CSNs.
1. it doesn't seem to work:
> ldapsearch -x -W -z1 "(uidnumber<=65534)" uidnumber
# extended LDIF
#
# LDAPv3
# base <dc=tu-clausthal, dc=de> (default) with scope subtree
# filter: (uidnumber<=65534)
# requesting: uidnumber
#
# search result
search: 2
result: 0 Success
text: inappropriate matching request
# numResponses: 1
(Yes, I have an equality index on uidnumber, and my bdb Database
contains that index, and I used 2.4.5 for that query)
2. who guarantees that due to indexing the highest uidnumber will be
returned? Could it be that it is just because OpenLDAP is currently
coded to do it that way? Is there a RFC requiring OpenLDAP to do so?
Nope, there's no spec for it, and portable applications cannot rely on it.
Sorry for the confusion.
bye
Christian
--
-- Howard Chu
Chief Architect, Symas Corp.
http://www.symas.com
Director, Highland Sun
http://highlandsun.com/hyc/
Chief Architect, OpenLDAP
http://www.openldap.org/project/