5.18.5 MODIFY
You will use this command to modify an LDAP entry. This command has three operations that may be performed - add, delete, and replace. It is important to note that these operations occur at the attribute level and not the DN record level. If you need to add or delete an entire DN then you should use the ADD or DELETE commands.
Syntax:
Command
|
Keyword
|
Value
|
Developer notes
|
MODIFY
|
DN
|
entry name
|
Required. The entry name that is to be modified.
|
|
Lists and Variables
The application must supply a working list from which the MODIFY command will pass the modified attributes. The working list must contain three fields as follows:
- The first field is mandatory and will contain the operation to be performed.
Suggested field length: Character field of length 1.
The three possible values for this field are:
- A for Add
- D for delete
- R for Replace.
- The second field is mandatory and will contain the attribute name for each modified attribute.
Suggested field length: you will need to ensure that the field is long enough to hold the longest possible attribute name for your LDAP Server. The field length will be character.
- The third field is mandatory. It will contain the attribute value for each modified attribute.
Suggested field length: you will need to ensure that the field is long enough to hold the longest possible attribute value for your LDAP Server. The field length will be character.
Example
MODIFY DN(cn=John, cn=users, o=ibmteldir) #WRKLST(ATMOD,ATNAME,ATVALUE)