|  | 
 | ||||
|        | |||||
|  | ||||||
| Other Library Functions | ||||||
| function | ldap.entry-exists | 
| Library: LDAP support (OMLDAP) Import: omldap.xmd | Return type: Switch Returns: True or false. | 
define external switch function ldap.entry-exists read-only ldap.attribute entry
Argument definitions
This function returns a switch value specifying whether an entry exists in the current ldap.attribute.
The shelf my-entry references the first entry that satisifed the search, keyed by the attribute name.
ldap.advance-entry advances to the next entry satisfying the search. ldap.entry-exists returns false when there are no more entries.
  import "omldap.xmd" prefixed by ldap.
  
  process
     local ldap.connection my-ldap
     local ldap.attribute my-entry variable
  
     set my-ldap to ldap.open 'www.stilo.com'
     ldap.search my-ldap
        base  "o=stilo.com"
        where  "(Department=RD)"
        into   my-entry
  
     repeat
        exit unless ldap.entry-exists my-entry
        output ldap.entry-name of my-entry || "%n"
        ldap.advance-entry my-entry
     again
Copyright © Stilo International plc, 1988-2008.