Hi everyone,
I am wanting to do a native SQL query as my complex joins I believe are beyond what Hibernate can handle.
Here is the code I am trying to do
Code:
Query wlQuery = session.createQuery(getHQLString(parms, types));
Query sqlQuery = session.createSQLQuery("select p.* from process p", "p", HibProcess.class);
The error I get is:
"Invalid column realId0_"
realId is the first column in the process table (realId).
What am I missing from here, the column is mapped like this
Code:
<id name="realId" column="realId" type="java.lang.Long">
<generator class="native"></generator>
</id>
What is it meaning when it says realId0_ is invalid? Is it missing from the object I am trying to bind to, do I have to specify it directly in the query? I am confused?