On 21 December 2011 11:42, henry human <henry_human@xxxxxxxx> wrote:
> Hi
> The XML
>
> <?xml version="1.0"?>
> <root>
> <Invoice>
> <DocumentReference>
> <ID>100</ID>
> </DocumentReference>
> </Invoice>
> <Invoice>
> <DocumentReference>
> <ID>200</ID>
> </DocumentReference>
> </Invoice>
> </root>
>
> Output should be: 1.100_2.200
a one liner is:
string-join(/root/Invoice/DocumentReference/ID/concat(position(), '.', .),
'_')
..but you can separate that out for readability.
--
Andrew Welch
http://andrewjwelch.com
|