Hi there,

just (re-) discovered that idm351 does not preserve XML attributes with do-reformat-op-attr, e.g.:


<do-reformat-op-attr name="P0001:KOSTL:none:115:10">
<arg-value>
<token-replace-first regex="^0+" replace-with="">
<token-local-variable name="current-value"/>
</token-replace-first>
</arg-value>
</do-reformat-op-attr>


Trace:


<?xml version="1.0" encoding="UTF-8"?><nds dtdversion="3.5" ndsversion="8.x">
<source>
<product version="?.?.?.?">DirXML</product>
<contact>Novell, Inc.</contact>
</source>
<input>
<modify class-name="P" event-id="SRV_SAPHR-MQ1:O_100_0000000000003679:P+00003679" src-dn="00003679" timestamp="20081124">
<association>00003679</association>
<modify-attr attr-name="P0001:KOSTL:none:115:10">
<remove-all-values/>
<add-value>
<value seqnr="000" timestamp="20000117-20000630" type="string">0000901203</value>
</add-value>
</modify-attr>
</modify>
</input>
</nds>
SRV_SAPHR-MQ1 :Applying policy: %+C%14CInput Transform%-C.
SRV_SAPHR-MQ1 : Applying to modify #1.
SRV_SAPHR-MQ1 : Evaluating selection criteria for rule 'Reformat mupCostCenter (P0001:KOSTL:none:115:10)'.
SRV_SAPHR-MQ1 : Rule selected.
SRV_SAPHR-MQ1 : Applying rule 'Reformat mupCostCenter (P0001:KOSTL:none:115:10)'.
SRV_SAPHR-MQ1 : Action: do-reformat-op-attr("P0001:KOSTL:none:115:10",token-replace-first("^0+","",token-local-variable("current-value"))).
SRV_SAPHR-MQ1 : arg-string(token-replace-first("^0+","",token-local-variable("current-value")))
SRV_SAPHR-MQ1 : token-replace-first("^0+","",token-local-variable("current-value"))
SRV_SAPHR-MQ1 : token-replace-first("^0+","",token-local-variable("current-value"))
SRV_SAPHR-MQ1 : token-local-variable("current-value")
SRV_SAPHR-MQ1 : Token Value: "0000901203".
SRV_SAPHR-MQ1 : Arg Value: "0000901203".
SRV_SAPHR-MQ1 : Token Value: "901203".
SRV_SAPHR-MQ1 : Arg Value: "901203".
SRV_SAPHR-MQ1 :Policy returned:
SRV_SAPHR-MQ1 :
<nds dtdversion="3.5" ndsversion="8.x">
<source>
<product version="?.?.?.?">DirXML</product>
<contact>Novell, Inc.</contact>
</source>
<input>
<modify class-name="P" event-id="SRV_SAPHR-MQ1:O_100_0000000000003679:P+00003679" src-dn="00003679" timestamp="20081124">
<association>00003679</association>
<modify-attr attr-name="P0001:KOSTL:none:115:10">
<remove-all-values/>
<add-value>
<value>901203</value>
</add-value>
</modify-attr>
</modify>
</input>
</nds>

Et viola @segnr and @timestamp are gone! Does anyone know of a smart way to preserve these, short of reimplementing a full version of do-reformat-op-attr with for-each and lots of xpath? Is that fixed/enhanced in IDM36?

Cheers, Lothar