Quantcast
Channel: Transact-SQL forum
Viewing all articles
Browse latest Browse all 23857

Convert data into XML on row basis

$
0
0

Hi all,

I have a table with col1 and col2 with 5 rows.

now I need data in XML

If I used XML Path than it return data in single row.

but I need 5 rows with XML data.

Row wise XML data.

<ID>1<ID><Name>hh<Name>

<ID>2<ID><Name>hhh<Name>

<ID>3<ID><Name>hhhh<Name>

<ID>4<ID><Name>hhhhh<Name>

Kindly help.


Viewing all articles
Browse latest Browse all 23857

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>