Skip to Main Content

DevOps, CI/CD and Automation

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

How to form an xml using a comma separated string in Xquery

890740May 7 2012 — edited May 9 2012
Hi 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.
This post has been answered by odie_63 on May 8 2012
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jun 6 2012
Added on May 7 2012
6 comments
484 views