title: Not all named parameters have been set in specific conditions
body: <p>I have using then following query in my Hibernate i.e createSQLQuery </p>
  
  <pre><code>SELECT to_char(dd, 'Mon YYYY') FROM generate_series('2013-01-01'::date, date_trunc('month', now()), '1 month') as dd 
  </code></pre>
  
  <p>which produces output when run in PostgreSQL as </p>
  
  <ol>
  <li>"Jan 2013" "Feb 2013" . . "Feb 2014"</li>
  </ol>
  
  <p>However while using it through createSQLQuery as below , 
  it throws "<strong>org.hibernate.QueryException: Not all named parameters have been set: [:date]</strong>"</p>
  
  <p>Please note that date has been used like '<strong>2013-01-01'::date</strong> </p>
  
  <pre><code>try{
              session = HibernateSessionFactory.getSession(); 
              tx = session.beginTransaction();
  
              Query query = session.createSQLQuery("SELECT to_char(dd, 'Mon YYYY') FROM generate_series('2013-01-01'::date, date_trunc('month', now()), '1 month') as dd");
              monthList = new ArrayList&lt;String&gt;();            
              monthList = query.list();
              tx.commit();
          }
  </code></pre>
  
  <p>Please suggest </p>