From: Todd P. <tc...@mt...> - 2002-03-14 14:39:37
|
Craig, If you know the DN you can do a base level search with a filter of objectclass=* (iPlanet/OpenLDAP) to retrieve everything in just that entry. If you only want certain attributes you can specify those in an array. For example: $mesg = $ldap->search(base => $dn, scope => "base", filter => "objectclass=*", @attrs); Hope that helps. -- Regards, ------------------------------------------------------------ | Todd Piket | Email: tc...@mt... | | Programmer/Analyst | Phone: (906) 487-1720 | | Distributed Computing Services | | | Michigan Technological University | | ------------------------------------------------------------ Craig Robinson wrote: > > Experts, > > Maybe a simple question, but I have no idea how to do it! > > Normally, when I do searches I specify a filter to seach for [eg. $filter=(uid=*);] and some attributes [eg. @attrs=qw(mail);]. However, I cannot use the DN as a filter [eg. $filter=(dn=cn=Craig Robinson);]. > > If you know the DN, does anyone know how to return a single (or a number of) attributes for that DN only? > > Much Thanks! > > Craig Robinson > Environmental Protection Agency > Tel: (07) 3006 4629 Fax: (07) 3247 6534 > Email: cra...@en... > > Visit us at: http://www.env.qld.gov.au > |