title: XSD Nested elements of the same name with different child elements
body: <p>I am currently re writing an XSD to be more specific when accepting data. There is a complexType to accept all elements with name "part" containing an attribute "partname", without validating any child nodes within the part. Here is the current complexType XSD code:</p>
  
  <pre><code>&lt;xs:complexType name="partType" mixed="true"&gt;
      &lt;xs:sequence&gt;
          &lt;xs:any maxOccurs="unbounded" processContents="lax" /&gt;
      &lt;/xs:sequence&gt;
      &lt;xs:attribute name="partname" type="stringtype" use="required" /&gt;
  &lt;/xs:complexType&gt;
  </code></pre>
  
  <p>And here is a sample of the types of "parts" I receive in XML:</p>
  
  <pre><code>&lt;part partname="customer"&gt;
      &lt;seq&gt;1&lt;/seq&gt;
      &lt;type&gt;owner&lt;/type&gt;
      &lt;part partname="conviction"&gt;
          &lt;convictionCode&gt;12345&lt;/convictionCode&gt;
          &lt;convictionDate&gt;2011-06-02&lt;/convictionDate&gt;
          &lt;fine /&gt;
          &lt;term /&gt;
          &lt;type /&gt;
          &lt;age&gt;22&lt;/age&gt;
          &lt;suspension&gt;0&lt;/suspension&gt;
      &lt;/part&gt;
      &lt;part partname="claim"&gt;
          &lt;dateOfLoss&gt;2010-05-05&lt;/dateOfLoss&gt;
          &lt;claimType&gt;Accident&lt;/claimType&gt;
          &lt;claimCost /&gt;
          &lt;claimFault&gt;No&lt;/claimFault&gt;
          &lt;type&gt;owner&lt;/type&gt;
      &lt;/part&gt;
  &lt;/part&gt;
  </code></pre>
  
  <p>I have had trouble finding information on how to achieve content validation when the same element comes in multiple forms and can nest within each other. </p>
  
  <p>Any recommendations of what syntax may be appropriate are appreciated</p>