list.get().method generate cast exeption
<p>I have written a code like this to fetch data from database using HQL:</p>

<pre><code>Query qr=sess.createQuery("select i.contract_Vcode,i.installment_date from Installment i where i.vcode=:instalVcode").setParameter("instalVcode", installVcode);
        qr.getNamedParameters();
List&lt;Installment&gt; li=null;
        li=qr.list();
int coVcode=li.get(0).getContract_Vcode();
</code></pre>

<p>As I know the contract_Vcode is an integer. But when I want to run it, the followed error happens:</p>

<pre><code>Error invoking Action using Hibernate Core Session / Transaction injection
java.lang.ClassCastException: [Ljava.lang.Object; cannot be cast to information.Installment
</code></pre>

<p>More over when I want to see the exact element like this,</p>

<pre><code>System.out.println("contract installDate is: "+li.get(0).getContract_Vcode());
</code></pre>

<p>same error happens. How can I fix this?</p>
