I'm creating a three tier web application, where I create my queries on the web tier but execute them on the backend tier. As far as I'm using Criteria queries everything is fine. I create a DetachedCriteria, pass it to the BackendTier, add the session, do the query and get my result.
But sometimes I would like to execute HQL queries. Cause the WebTier is unaware of any Session, I cannot use Session.createQuery(), so I'm looking for something like a detached Query. Is there something like the DetachedCriteria for HQL? Or is there someway I can create my own Session Implementation, if it's possible at all?
Hibernate version: 3.05
|