title: QueryParameterException: Position beyond number of declared ordinal parameters
body: <p>I am using Spring Data JPA to generate a very simple query method, but getting the following error:</p>
  
  <pre><code>java.lang.IllegalArgumentException: org.hibernate.QueryParameterException:
  Position beyond number of declared ordinal parameters. Remember that ordinal parameters are 1-based! Position: 1
  </code></pre>
  
  <p>This is my method:</p>
  
  <pre><code>@Query(" select new AccessLog(acct, auth) from Authentication auth, RadiusAcct acct "
          + " where auth.startDate &gt;= ?1 ")
  List&lt;AccessLog&gt; findUnconsolidatedRecords(Date start);
  </code></pre>
  
  <p>Any ideas on what is going wrong? This is bugging me specially because I have written hundreds of queries like that before, and this one looks perfectly normal.</p>