#include <ldap.h> int ldap_modrdn_s( LDAP *ld, const char *dn, const char *newrdn, int deleteoldrdn)
The ldap_modrdn_s() function is used to perform an LDAP modify relative distinguished name (RDN) operation. The function takes the distinguished name of the entry whose RDN is to be changed, and newrdn, the new RDN to give the entry. The deleteoldrdn parameter is used as a boolean value to indicate whether the old RDN values should be deleted from the entry or not.
ldap_modrdn_s() performs a synchronous request.
In LDAP V2, the ldap_modrdn() and ldap_modrdn_s() APIs were used to change the name of an LDAP entry. They could only be used to change the least significant component of a name (the RDN or relative distinguished name). LDAP V3 provides the Modify DN protocol operation that allows more general name change access. The ldap_rename() and ldap_rename_s() routines are used to change the name of an entry, and the use of the ldap_modrdn() and ldap_modrdn_s() routines are deprecated.
No i5/OS authority is required. All authority checking is done by the LDAP server.
The ldap_modrdn_s() will return an LDAP error code if not successful. See LDAP Client API Error Conditions for possible LDAP error code values.
The following message may be sent from this function.
Message ID | Error Message Text |
---|---|
CPF3CF2 E | Error(s) occurred during running of ldap_modrdn_s API. |
Top | LDAP APIs | APIs by category |