I was thinking about a use case of a string, that is kind of JSON like.


So Split on : and I get a nodeset of values in variable SPLIT.

I can address nodes by $SPLIT[1] and $SPLIT[4] to get the first and last

Now I want to change the third one. Reading out of it is easy.

I was trying to think of a way to 'poke' a value into one of those

Clone by XPATH, cloning $NEW-VALUE into $SPLIT[3] (insert after, or
insert before $SPLIT[4]) failed with a cute error I did not record.
PS: Slightly different issue if $NEW-VALUE was a string or a nodeset.

Then I tried for-each over the nodeset, and set current-node to XPATH of
$SPLIT[3] and get a very cute error about current-node being a read only
variable in Simulator.

Thus far I have found some clever error messages I never saw before, but
no great approach.

One way I found was to
set local variable SECOND-SPLIT as a nodeset of:
Local Variable NEW-VALUE

I.e. Just rebuild the whole thing.

(Join() on : works perfect to reassemble it either way).

I am wondering if I forgot some approach to push my value into the

BraveBraveSirRobin's Profile: https://forums.netiq.com/member.php?userid=2812
View this thread: https://forums.netiq.com/showthread.php?t=45040