title: How to resolve the error 'nexpected element (uri:"", local:"Create"). Expected elements are <{}Create>'?
body: <p>I have a problem with my JAXB:</p>
  <pre><code>&lt;element name=&quot;create&quot;&gt;
      &lt;complexType&gt;
          &lt;sequence&gt;
              &lt;element name=&quot;name&quot; type=&quot;string&quot;&gt;&lt;/element&gt;
          &lt;/sequence&gt;
      &lt;/complexType&gt;
  &lt;/element&gt;
  </code></pre>
  <p>My XML:</p>
  <pre><code>&lt;Create&gt;
  &lt;name&gt; coco &lt;/name&gt;
  &lt;/Create&gt;
  </code></pre>
  <p>My Java:</p>
  <pre><code>JAXBContext context = JAXBContext.newInstance(&quot;MyPackage&quot;);
   Unmarshaller decodeur =    context.createUnmarshaller();
  System.out.println(&quot;text : &quot; + message);
  msgObject = decodeur.unmarshal(sr);  
       if (msgObject instanceof Create)
  
  {
        System.out.println(&quot; action&quot;);
  }
  
          
                  
  </code></pre>
  <p>And I have this:</p>
  <blockquote>
  <p>unexpected element (uri:&quot;&quot;, local:&quot;Create&quot;). Expected elements are &lt;{http://www.example.org/XSD_Maths}create&gt;</p>
  </blockquote>
  <p>And my code stopped at this line:</p>
  <pre><code> msgObject = decodeur.unmarshal(sr);  
  </code></pre>
  <p>Is my XML OK or is there a problem with it? I'm not sure why I'm getting this error.</p>