title: How to into data into a MySQL using JPA and @Query named Parameters
body: <p>I am getting the following error:</p>
  
  <pre><code>Using named parameters for method public static void com.htd.repository.MaterialRepository.uploadMaterialData(java.lang.String,java.math.BigDecimal,java.lang.String,java.math.BigDecimal,java.math.BigDecimal) but parameter 'material_number' not found in annotated query 'INSERT INTO hillcresttooldie VALUES (?,?,?,?,?)'!
  </code></pre>
  
  <p>I read the documention at:
  <a href="http://docs.spring.io/spring-data/jpa/docs/1.4.3.RELEASE/reference/html/jpa.repositories.html" rel="nofollow">http://docs.spring.io/spring-data/jpa/docs/1.4.3.RELEASE/reference/html/jpa.repositories.html</a> but I am still having issues. I was under the impression JPA created queries for us. I am used to writing out the queries until I cam across this awesome piece of technology.</p>
  
  <pre><code>public interface MaterialRepository extends JpaRepository&lt;Material,Long&gt; {
  
      @Query("INSERT INTO hillcresttooldie VALUES (?,?,?,?,?)")
      static void uploadMaterialData(String material_number,BigDecimal material_thickness,String material_size,BigDecimal lb_per_sheet,BigDecimal dollar_per_lb) {
  
  
      }
  }
  </code></pre>
  
  <p>Trying to use the query in the MaterialResource.java file</p>
  
  <pre><code>//puts materials into map and the key is the material number
                  materialMap.put(materialValue, material);
  
                  MaterialRepository.uploadMaterialData(material.getMaterial_number(), material.getMaterial_thickness(),
                          material.getMaterial_size(), material.getLb_per_sheet(), material.getDollar_per_lb());
  </code></pre>