Hi,

I have a multi valued attribute called legacyExchangeDn that holds mail
addresses.
The addresses are in string format and looks like
SMTP:address@domain.com, smtp:address@domain.com and
X500:/dc/dc/ou/ou/cn.

The attribute should only have one value that has SMTP: as prefix.

Now I have several objects that have several values starting with SMTP:
so I would like to write a rule in my null driver that cleans this up.

I have no problem creating the valid SMTP: value but I would like the
other values to stay there.

The rule should remove all existing values starting with SMTP: and then
add the new value.

I have tried with this and similar rules but can't get it to work:

<do-for-each>
<arg-node-set>
<token-src-attr name="legacyExchangeDn"/>
</arg-node-set>
<arg-actions>
<do-if>
<arg-conditions>
<and>
<if-local-variable mode="case" name="current-node"
op="equal">SMTP:.*</if-local-variable>
</and>
</arg-conditions>
<arg-actions>
<do-remove-src-attr-value name="legacyExchangeDn">
<arg-value>
<token-local-variable name="current-node"/>
</arg-value>
</do-remove-src-attr-value>
</arg-actions>
<arg-actions/>
</do-if>
</arg-actions>
</do-for-each>


--
-----------------------------------
joakim . ganse_@_ accept-it . se
------------------------------------------------------------------------
joakim_ganse's Profile: http://forums.novell.com/member.php?userid=6236
View this thread: http://forums.novell.com/showthread.php?t=387903