I am creating an XML document from a SQL query and i was wondering if there is a way to output the version and encoding tag via the SQL Query?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
The FOR XML was new in SQL Server 2005, right? So you’d have to manually assemble the XML:
It’s up to you to transmit it in the encoding you claim in the XML header.