How to form an xml using a comma separated string in Xquery
890740May 7 2012 — edited May 9 2012Hi All,
In my application I need to write an Xquery which should form an xml document. The input to the XQuery will be an xml with one element that has comma separated strings. For
example
<Root>
<StringComma>Hi,Hello,Welcome</StringComma>
</Root>
I need to form an xml in such a way that it should have as many tags as the strings in <StringComma> element of the above. For instance what I exactly want is
<Root1>
<String1>Hi</String1>
<String2>Hello</String2>
<String3>Welcome</String3>
</Root1>
something like this. How could we do this usin XQuery. Kindly help me in this.
Thanks.