title: xsd schema not working against the xml file
body: <p>having a nightmare here with XSD and XML. Got 1 simple xml file (representing my table in database) and a XSD Schema, I was trying to validate them against each other, and every single time some errors come up. The best thing is different validators show totally different errors on the same files. This first time I'm dealing with this and have no experience with XML. Could someone please point out my errors correctly and briefly explain them? I'm not looking for you guys doing it all for me. Just put me in the right direction.
  Thanks, Andy</p>
  
  <p>XSD Schema</p>
  
  <pre><code>    &lt;?xml version="1.0"?&gt;
  &lt;xs:schema version="1.0"
             xmlns:xs="http://www.w3.org/2001/XMLSchema"
             targetNamespace="http://www.w3schools.com"
             xmlns="http://www.w3schools.com"
             elementFormDefault="qualified"&gt;
    &lt;xs:element name="Users"&gt;
      &lt;xs:complexType&gt;
        &lt;xs:sequence&gt;
          &lt;xs:element name="user"&gt;
            &lt;xs:complexType&gt;
              &lt;xs:sequence&gt;
                &lt;xs:element name="userID"&gt;
                  &lt;xs:simpleType&gt;
                    &lt;xs:restriction base="xs:integer"&gt;
                      &lt;xs:minInclusive value="0"/&gt;
                      &lt;xs:maxInclusive value="120"/&gt;
                    &lt;/xs:restriction&gt;
                  &lt;/xs:simpleType&gt;
                &lt;/xs:element&gt;
                &lt;xs:element name="firstName"&gt;
                  &lt;xs:simpleType&gt;
                    &lt;xs:restriction base="xs:string"&gt;
                      &lt;xs:pattern value="([a-zA-Z])*"/&gt;
                      &lt;xs:minLength value="2"/&gt;
                      &lt;xs:maxLength value="28"/&gt;
                    &lt;/xs:restriction&gt;
                  &lt;/xs:simpleType&gt;
                &lt;/xs:element&gt;
                &lt;xs:element name="lastName"&gt;
                  &lt;xs:simpleType&gt;
                    &lt;xs:restriction base="xs:string"&gt;
                      &lt;xs:pattern value="([a-zA-Z])*"/&gt;
                      &lt;xs:minLength value="2"/&gt;
                      &lt;xs:maxLength value="28"/&gt;
                    &lt;/xs:restriction&gt;
                  &lt;/xs:simpleType&gt;
                &lt;/xs:element&gt;
                &lt;xs:element name="email"&gt;
                  &lt;xs:simpleType&gt;
                    &lt;xs:restriction base="xs:string"&gt;
                      &lt;xs:pattern value="^([a-zA-Z0-9_\-\.]+)@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.)|(([a-zA-Z0-9\-]+\.)+))([a-zA-Z]{2,4}|[0-9]{1,3})(\]?)$"/&gt;
                      &lt;xs:minLength value="6"/&gt;
                      &lt;xs:maxLength value="80"/&gt;
                    &lt;/xs:restriction&gt;
                  &lt;/xs:simpleType&gt;
                &lt;/xs:element&gt;
                &lt;xs:element name="DOB"&gt;
                  &lt;xs:simpleType&gt;
                    &lt;xs:restriction base="xs:date"&gt;
                    &lt;/xs:restriction&gt;
                  &lt;/xs:simpleType&gt;
                &lt;/xs:element&gt;
                &lt;xs:element name="tellNo"&gt;
                  &lt;xs:simpleType&gt;
                    &lt;xs:restriction base="xs:string"&gt;
                      &lt;xs:pattern value="[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9] "/&gt;
                    &lt;/xs:restriction&gt;
                  &lt;/xs:simpleType&gt;
                &lt;/xs:element&gt;
                &lt;xs:element name="userTypeID"&gt;
                  &lt;xs:simpleType&gt;
                    &lt;xs:restriction base="xs:integer"&gt;
                      &lt;xs:minInclusive value="0"/&gt;
                      &lt;xs:maxInclusive value="120"/&gt;
                    &lt;/xs:restriction&gt;
                  &lt;/xs:simpleType&gt;
                &lt;/xs:element&gt;
              &lt;/xs:sequence&gt;
            &lt;/xs:complexType&gt;
          &lt;/xs:element&gt;
        &lt;/xs:sequence&gt;
      &lt;/xs:complexType&gt;
    &lt;/xs:element&gt;
  &lt;/xs:schema&gt;
  </code></pre>
  
  <p>XML file</p>
  
  <pre><code>    &lt;?xml version="1.0" encoding="UTF-8"?&gt;
  &lt;Users xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
      xsi:noNamespaceSchemaLocation="user.xsd"&gt;
  
    &lt;user userid="1"&gt;
          &lt;firstName&gt;Andrew&lt;/firstName&gt;
          &lt;lastName&gt;Golota&lt;/lastName&gt;
          &lt;email&gt;a.golota@wbc.us&lt;/email&gt;
          &lt;DOB&gt;1964-10-24&lt;/DOB&gt;
          &lt;tellNo&gt;078222446589&lt;/tellNo&gt;
          &lt;userTypeID&gt;1&lt;/userTypeID&gt;
      &lt;/user&gt;
  
      &lt;user userid="13"&gt;
          &lt;firstName&gt;Barrack&lt;/firstName&gt;
          &lt;lastName&gt;Obama&lt;/lastName&gt;
          &lt;email&gt;b.obama@whitehouse.us&lt;/email&gt;
          &lt;DOB&gt;1970-08-12&lt;/DOB&gt;
          &lt;tellNo&gt;079886365212&lt;/tellNo&gt;
          &lt;userTypeID&gt;3&lt;/userTypeID&gt;
      &lt;/user&gt;
  
      &lt;user userid="11"&gt;
          &lt;firstName&gt;Bill&lt;/firstName&gt;
          &lt;lastName&gt;Clinton&lt;/lastName&gt;
          &lt;email&gt;b.clinton@whitehouse.us&lt;/email&gt;
          &lt;DOB&gt;1960-12-07&lt;/DOB&gt;
          &lt;tellNo&gt;078537278867&lt;/tellNo&gt;
          &lt;userTypeID&gt;2&lt;/userTypeID&gt;
      &lt;/user&gt;
  
      &lt;user userid="5"&gt;
          &lt;firstName&gt;Michael&lt;/firstName&gt;
          &lt;lastName&gt;Grant&lt;/lastName&gt;
          &lt;email&gt;m.grant1966@wbc.us&lt;/email&gt;
          &lt;DOB&gt;1966-03-08&lt;/DOB&gt;
          &lt;tellNo&gt;078339789608&lt;/tellNo&gt;
          &lt;userTypeID&gt;4&lt;/userTypeID&gt;
      &lt;/user&gt;
  
      &lt;user userid="2"&gt;
          &lt;firstName&gt;Mike&lt;/firstName&gt;
          &lt;lastName&gt;Tyson&lt;/lastName&gt;
          &lt;email&gt;m.tyson@wbc.us&lt;/email&gt;
          &lt;DOB&gt;1966-12-01&lt;/DOB&gt;
          &lt;tellNo&gt;076255545422&lt;/tellNo&gt;
          &lt;userTypeID&gt;1&lt;/userTypeID&gt;
      &lt;/user&gt;
  
      &lt;user userid="4"&gt;
          &lt;firstName&gt;Mike&lt;/firstName&gt;
          &lt;lastName&gt;Mollo&lt;/lastName&gt;
          &lt;email&gt;m.mollo@wbc.us&lt;/email&gt;
          &lt;DOB&gt;1970-09-07&lt;/DOB&gt;
          &lt;tellNo&gt;076255545117&lt;/tellNo&gt;
          &lt;userTypeID&gt;3&lt;/userTypeID&gt;
      &lt;/user&gt;
  
      &lt;user userid="12"&gt;
          &lt;firstName&gt;Monica&lt;/firstName&gt;
          &lt;lastName&gt;Levinsky&lt;/lastName&gt;
          &lt;email&gt;m.levinsky@slutload.com&lt;/email&gt;
          &lt;DOB&gt;1988-12-06&lt;/DOB&gt;
          &lt;tellNo&gt;078553323285&lt;/tellNo&gt;
          &lt;userTypeID&gt;1&lt;/userTypeID&gt;
      &lt;/user&gt;
  
      &lt;user userid="14"&gt;
          &lt;firstName&gt;Osama&lt;/firstName&gt;
          &lt;lastName&gt;BinLaden&lt;/lastName&gt;
          &lt;email&gt;o.binladen@hideout.com&lt;/email&gt;
          &lt;DOB&gt;1926-06-06&lt;/DOB&gt;
          &lt;tellNo&gt;078552592921&lt;/tellNo&gt;
          &lt;userTypeID&gt;2&lt;/userTypeID&gt;
      &lt;/user&gt;
  
      &lt;user userid="3"&gt;
          &lt;firstName&gt;Riddick&lt;/firstName&gt;
          &lt;lastName&gt;Bowe&lt;/lastName&gt;
          &lt;email&gt;r.bowe@wbc.us&lt;/email&gt;
          &lt;DOB&gt;1962-02-14&lt;/DOB&gt;
          &lt;tellNo&gt;078222556575&lt;/tellNo&gt;
          &lt;userTypeID&gt;2&lt;/userTypeID&gt;
      &lt;/user&gt;
  
      &lt;user userid="0"&gt;
          &lt;firstName&gt;Tomasz&lt;/firstName&gt;
          &lt;lastName&gt;Adamek&lt;/lastName&gt;
          &lt;email&gt;t.adamek@wbc.us&lt;/email&gt;
          &lt;DOB&gt;1970-04-04&lt;/DOB&gt;
          &lt;tellNo&gt;077456757842&lt;/tellNo&gt;
          &lt;userTypeID&gt;1&lt;/userTypeID&gt;
      &lt;/user&gt;
  
  &lt;/Users&gt;
  </code></pre>