Following code will create xml file from sql server table.
SQL Server Table
XML Output
....
....
....
....
....
Script to convert sql server table to xml file
declare @XmlOutput xml
set @XmlOutput =
(select BlogId, Title, ContentValue, CreationDate from Blogs
FOR XML AUTO, ROOT('MyRoot'), ELEMENTS)
select @XmlOutput
No comments:
Post a Comment