It depends on how that "someAttribute" is defined in schema. There, many attributes are SINGLE VALUE bound, and that means that attributes of this type can hold only a single value instance and when user ldapmodifies attributes like these, the old value always gets replaced by the new one. I 'm not sure whether user could define NON SINGLE VALUE bound attributes, in that case you could probably use the -a flag of ldapmodify to insert more than one value instance for a specific attribute. May be our folk knows more about that issue? Un charlie derr wrote: > Hi all, > My question is probably best explained with a (simplified, > unrealistic) > example. > > Let's say I have an entry: > > dn: uid=someperson,ou=people > objectClass: person > .. > .. > .. > uid: someperson > someAttribute: value1 > .. > .. > .. > > If I now create a file called simple.ldif consisting of just two lines: > > dn: uid=someperson,ou=people > someAttribute: value2 > > and then execute: > > ldapmodify -f simple.ldif > > the result is that value2 does get added, but value1 disappears. I've > looked through the ldapmodify man page and also experimented with the > php function ldap_modify() but haven't discovered a way to do this > simply. Obviously I could first do an ldapsearch, select any > existing value(s), append the new one I wish to add, and then > perform my ldapmodify, but that seems unnecessarily complex for > something that I would think is a fairly common use case. > Is there an easy way to accomplish this? > > Thanx very much in advance, > ~c
Attachment:
smime.p7s
Description: S/MIME Cryptographic Signature