Adds the specified attribute or attribute value. If the attribute type does not
currently exist for the entry, then the attribute and its corresponding value are
created. If the attribute type already exists for the entry, then the specified
attribute value is added to the existing value. If the particular attribute value
already exists for the entry, then the operation fails and the server returns an
error.
•
attribute
replace:
The specified values are used to entirely replace the attribute's value(s). If the
attribute does not already exist, it is created. If no replacement value is
specified for the attribute, the attribute is deleted.
attribute
•
delete:
The specified attribute is deleted. If more than one value of an attribute exists
for the entry, then all values of the attribute are deleted in the entry. To delete
just one of many attribute values, specify the attribute and associated value on
the line following the delete change operation.
This section contains the following topics:
•
Adding Attributes to Existing Entries Using LDIF
•
Changing an Attribute Value Using LDIF
•
Deleting All Values of an Attribute Using LDIF
•
Deleting a Specific Attribute Value Using LDIF
Adding Attributes to Existing Entries Using LDIF
You use
changetype:modify
attribute value to an entry.
For example, the following LDIF update statement adds a telephone number to the
entry:
dn: cn=Barney Fife,ou=People,dc=example,dc=com
changetype: modify
add: telephonenumber
telephonenumber: 555-1212
The following example adds two telephone numbers to the entry:
dn: cn=Barney Fife,ou=People,dc=example,dc=com
changetype: modify
add: telephonenumber
telephonenumber: 555-1212
telephonenumber: 555-6789
with the add operation to add an attribute and an
Chapter 2
LDIF Update Statements
Creating Directory Entries
63
Need help?
Do you have a question about the NETSCAPE DIRECTORY SERVER 6.01 - ADMINISTRATOR and is the answer not in the manual?
Questions and answers