Write a SELECT statement that returns an XML document that contains all of the c
ID: 3675000 • Letter: W
Question
Write a SELECT statement that returns an XML document that contains all of the current shipping addresses for the customers in the database. This document should include one element for each of these columns: FirstName, LastName, Line1, Line2, City, State, and ZipCode. Then, save the XML document thats returned in a file named CustomerAddresses.xml. Finally, generate an XML schema for the file and save it in a file named CustomerAddresses.xsd I mi
I just need this one code. The rest will fall in to place.
Explanation / Answer
USE DATABASE_NAME
GO
SELECT Cust.FirstName,
Cust.LastName,
Cust.Line1,
Cust.Line2,
Cust.City,
Cust.State,
Cust.ZipCode
FROM Customer Cust
FOR XML AUTO
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.