title: OpenXml returns null for elements inside XML
body: <pre><code>Declare @xml xml,
  @y int
  set @xml= '&lt;ContactUpdates&gt;
         &lt;Contact VendorID="4"&gt;&lt;LastName&gt;McCrystle&lt;/LastName&gt;
         &lt;FirstName&gt;Timothy&lt;/FirstName&gt;
         &lt;/Contact&gt;
         &lt;Contact VendorID="10"&gt;
          &lt;LastName&gt;Flynn&lt;/LastName&gt;
          &lt;FirstName&gt;Erin&lt;/FirstName&gt;
          &lt;/Contact&gt;&lt;/ContactUpdates&gt;'
  
  
  Exec sp_xml_preparedocument @y output, @xml;
  Select * from openxml(@y,'/ContactUpdates/Contact')
    With (VendorID Varchar(20),
          LastName Varchar(30),
          FirstName Varchar(30))`
  </code></pre>
  
  <p><img src="https://i.stack.imgur.com/04YIf.png" alt="The result is"></p>
  
  <p>I do not know where has the mistake been done. Please help me out with this.</p>