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

Problem searching on address/fax in inetOrgPerson



Hi,

I'm trying to setup an address book type application with OpenLDAP
2.0.14 and am runnign into a problem where I can add data to the database
but I can't query on the postalAddress, homePostalAddress and
facsimileTelephoneNumber fields (inetOrgPerson schema).  I'm using the
bundled schemas.  An illustration with one data set:

# Keith Mitchell, AddressBook, pictus, net
dn: cn=Keith Mitchell,ou=AddressBook,dc=pictus,dc=net
objectClass: inetOrgPerson
sn: Mitchell
uid: kmitch
title: Misc 1
homePostalAddress: 1 Home Way
homePhone: +1 000 000 0000
mail: bitbucket@guru.org
description: Me
st: ST
l: City
telephoneNumber: +1 000 000 0000
postalCode: 00000
pager: +1 000 000 0000
cn: Keith Mitchell
mobile: +1 000 000 0000
labeledURI: http://www.guru.org/
postalAddress: 1 Business Way
givenName: Keith
facsimileTelephoneNumber: +1 000 000 0000


Search... (including postalAddress, homePostalAddress):

[inferno Tue 1:58pm]:/usr/local/etc/openldap# ldapsearch -D 'cn=root,dc=pictus,dc=net' -b 'dc=pictus,dc=net' '(| (& (sn=Mitchell)(homePostalAddress=1 Home Way)(title=Misc 1)(uid=kmitch)(mail=bitbucket@guru.org)(homePhone=+1 000 000 0000)(description=Me)(st=ST)(l=City)(telephoneNumber=+1 000 000 0000)(postalCode=00000)(pager=+1 000 000 0000)(cn=Keith Mitchell)(mobile=+1 000 000 0000)(labeledURI=http://www.guru.org/)(postalAddress=1 Business Way)(givenName=Keith)))'
version: 2

#
# filter: (| (& (sn=Mitchell)(homePostalAddress=1 Home Way)(title=Misc 1)(uid=kmitch)(mail=bitbucket@guru.org)(homePhone=+1 000 000 0000)(description=Me)(st=ST)(l=City)(telephoneNumber=+1 000 000 0000)(postalCode=00000)(pager=+1 000 000 0000)(cn=Keith Mitchell)(mobile=+1 000 000 0000)(labeledURI=http://www.guru.org/)(postalAddress=1 Business Way)(givenName=Keith)))
# requesting: ALL
#

# search result
search: 2
result: 0 Success

# numResponses: 1


Search (include postalAddress):
[inferno Tue 1:58pm]:/usr/local/etc/openldap# ldapsearch -D 'cn=root,dc=pictus,dc=net' -b 'dc=pictus,dc=net' '(| (& (sn=Mitchell)(title=Misc 1)(uid=kmitch)(mail=bitbucket@guru.org)(homePhone=+1 000 000 0000)(description=Me)(st=ST)(l=City)(telephoneNumber=+1 000 000 0000)(postalCode=00000)(pager=+1 000 000 0000)(cn=Keith Mitchell)(mobile=+1 000 000 0000)(labeledURI=http://www.guru.org/)(postalAddress=1 Business Way)(givenName=Keith)))'
version: 2

#
# filter: (| (& (sn=Mitchell)(title=Misc 1)(uid=kmitch)(mail=bitbucket@guru.org)(homePhone=+1 000 000 0000)(description=Me)(st=ST)(l=City)(telephoneNumber=+1 000 000 0000)(postalCode=00000)(pager=+1 000 000 0000)(cn=Keith Mitchell)(mobile=+1 000 000 0000)(labeledURI=http://www.guru.org/)(postalAddress=1 Business Way)(givenName=Keith)))
# requesting: ALL
#

# search result
search: 2
result: 0 Success

# numResponses: 1


Search (without homePostalAddress, postalAddress):
[inferno Tue 1:59pm]:/usr/local/etc/openldap# ldapsearch -D 'cn=root,dc=pictus,dc=net' -b 'dc=pictus,dc=net' '(| (& (sn=Mitchell)(title=Misc 1)(uid=kmitch)(mail=bitbucket@guru.org)(homePhone=+1 000 000 0000)(description=Me)(st=ST)(l=City)(telephoneNumber=+1 000 000 0000)(postalCode=00000)(pager=+1 000 000 0000)(cn=Keith Mitchell)(mobile=+1 000 000 0000)(labeledURI=http://www.guru.org/)(givenName=Keith)))'
version: 2

#
# filter: (| (& (sn=Mitchell)(title=Misc 1)(uid=kmitch)(mail=bitbucket@guru.org)(homePhone=+1 000 000 0000)(description=Me)(st=ST)(l=City)(telephoneNumber=+1 000 000 0000)(postalCode=00000)(pager=+1 000 000 0000)(cn=Keith Mitchell)(mobile=+1 000 000 0000)(labeledURI=http://www.guru.org/)(givenName=Keith)))
# requesting: ALL
#

# Keith Mitchell, AddressBook, pictus, net
dn: cn=Keith Mitchell,ou=AddressBook,dc=pictus,dc=net
objectClass: inetOrgPerson
sn: Mitchell
uid: kmitch
title: Misc 1
homePostalAddress: 1 Home Way
homePhone: +1 000 000 0000
mail: bitbucket@guru.org
description: Me
st: ST
l: City
telephoneNumber: +1 000 000 0000
postalCode: 00000
pager: +1 000 000 0000
cn: Keith Mitchell
mobile: +1 000 000 0000
labeledURI: http://www.guru.org/
postalAddress: 1 Business Way
givenName: Keith

# search result
search: 2
result: 0 Success

# numResponses: 2
# numEntries: 1


As you can see, it works without postalAddress and homePostalAddress but it
doesn't with them in there....  Although not illustrated above,
facsimileTelephoneNumber behaves the same way.  Has anyone run into this?

Forgive me if this has been hashed out before.... I just subscribed to
the list and didn't see it mentioned in the archives (after a quick search).


Thanks.

-- 
Keith Mitchell
Email: kmitch@guru.org				PGP key available upon request