[
http://opensource.atlassian.com/projects/hibernate/browse/HHH-2701?page=c...
]
Nicholas Albion commented on HHH-2701:
--------------------------------------
Not all of my tables are mapped to @Entities, and from time to time I need to write native
queries just because I'm joining on these non-Hibernate tables. I posted this
message some time ago and have actually forgotten exactly what I was trying to do at the
time, I think I was going to generate an SQL string and then programatically modify it by
search & replace or appending something like "JOIN ON table WHERE field=?".
I think that the question is clear - it seems impossible to use the
"Example.toSqlString()" method because the docs say that
"CriteriaQuery" is not used by application code - therefore
Example.toSqlString() can not be used by application code either.
org.hibernate.criterion.Example.toSqlString()
---------------------------------------------
Key: HHH-2701
URL:
http://opensource.atlassian.com/projects/hibernate/browse/HHH-2701
Project: Hibernate3
Issue Type: Improvement
Components: documentation
Reporter: Nicholas Albion
I'm trying to create a query by example, and hopefully adapt the SQL to include joins
on non-HSQL columns.
The documentation is confusing for
org.hibernate.criterion.Example.toSqlString(Criteria criteria, CriteriaQuery
criteriaQuery)
I'm not sure how to obtain the CriteriaQuery parameter. Google only managed to find
an unanswered forum posting asking the same question. The javadocs for CriteriaQuery only
adds confusion to the matter:
Interface CriteriaQuery: This interface is not used by application code.
(
http://www.hibernate.org/hib_docs/v3/api/org/hibernate/criterion/Criteria...)
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://opensource.atlassian.com/projects/hibernate/secure/Administrators....
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira