I have never used XML in SQL Server 2008, I need to extract a list of customers into a variable table how do you do it?
Given that I have a column called CustomerList
in a Sales
table that looks like something like below how do I extract the list of customers in sql?
<ArrayOfCustomers xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<Customer>
<ItemId>1</ItemId>
<Value>Mr Smith</Value>
</Customer>
<Customer>
<ItemId>2</ItemId>
<Value>Mr Bloggs</Value>
</Customer>
</ArrayOfCustomers>