scrotch wrote:
Can you post the code where you make the query and where you cast an item in the list?
Thanks for you help, but the problem was that i try to use the next sintax:
"Query query = session.createQuery("select p.id, p.descripcion from prueba p"); "
and to retrieve the list
"query.list()"
In the reference manual of hibernate i find a diferent sintax, then change my code to:
Prueba fritz =new Prueba();
Query query = session.createSQLQuery("select {fritz.*} from prueba {fritz}", "fritz", Prueba.class);
to retrieve list: rows = query.list();
in this way i don't need cast the list elements!!
Thanks for your answer!!!!!!