Top "Hql" questions

Use this tag for questions concerning "Hibernate Query Language" (HQL), a query language used by Hibernate and NHibernate.

"where exists" in Hibernate HQL

How can I write a "not exists" query in HQL? I am trying to get an HQL not exists query …

java hibernate orm hql
How do I use order by in HQL?

I want to execute my HQL query like this: Query queryPayment=sixSession.createQuery("from Payment where vcode=:p_Vcode or (…

java hql
What's wrong with this HQL? "No data type for node"

session.createQuery("Select attribute from GoodsSection tgs " + "join gs.ascendants ags join ags.attributes attribute " + "where attribute.outerId = :outerId and …

java hibernate hql
JpaRepository Not supported for DML operations [delete query]

I have written a query to delete some objects in my interface extending JPaRepository, but when I execute the query …

java spring hibernate spring-data-jpa hql
Optional parameters with named query in Hibernate?

Is there any way to specify optional parameters (such as when search parameters are provided from a form and not …

java hibernate orm hql named-query
Proper way of writing a HQL in ( ... ) query

Assuming that I want to write the following HQL query: FROM Cat c WHERE c.id IN (1,2,3) what is the …

hibernate hql
How to retrieve only certain fields of an entity in JPQL or HQL? What is the equivalent of ResultSet in JPQL or HQL?

In JPQL, I can retrieve entities by : query = entityManager.createQuery("select c from Category c"); List<Category> categories = …

hibernate orm hql jpql
How to test HQL queries?

I'm searching for a fast (really fast) way to test changes to hibernate queries. I have a huge application with …

java hibernate testing hql environment
Hibernate and Unexpected end of Subtree exception

I'm a newbie to Hibernate. I have an Item POJO which contains a Set<String> consisting of labels. …

java hibernate hql
Hibernate Criteria vs HQL: which is faster?

I have been reading some anwers, but i'm still confused. ¿Why? because the differences that you have mentioned do not …

performance hibernate hql hibernate-criteria