I'd like to do some statistical queries to build a reporting module to my application. I'd like to know how to do that with Hibernate.
I explain :
Statistical data can be requested and retrieved under "array". I remember that Jdbc API allows to get ResultSet that column number is unpredictable.
Code:
"select id,name from mytable order by id;"
brings me a ResultSet contening 2 columns and x lines.
Code:
"select count(*),id,name,lastname from mytable order by id;"
brings me a ResultSet contening 4 columns and x lines.
I'd like to know how can I use Hibernate to generate a persistable (readable only) bean that contains an "array" that looks like ResultSet working.
Can I map those "Array" by any way ?
Sould I use JDBC API proposed by Hibernate Session
Code:
session.connection()
Thanks for your help.
Have a nice day.