title: How do you read XML column in SQL Server 2008?
body: <p>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?</p>
  
  <p>Given that I have a column called <code>CustomerList</code> in a <code>Sales</code> table that looks like something like below how do I extract the list of customers in sql?</p>
  
  <pre><code>&lt;ArrayOfCustomers xmlns:xsd="http://www.w3.org/2001/XMLSchema"        
                    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"&gt;
     &lt;Customer&gt;
         &lt;ItemId&gt;1&lt;/ItemId&gt;
         &lt;Value&gt;Mr Smith&lt;/Value&gt;
     &lt;/Customer&gt;
     &lt;Customer&gt;
        &lt;ItemId&gt;2&lt;/ItemId&gt;
        &lt;Value&gt;Mr Bloggs&lt;/Value&gt;
     &lt;/Customer&gt;
  &lt;/ArrayOfCustomers&gt;
  </code></pre>