Introduction HQL (Hibernate Query Language)
In this section, you will learn about hibernate query language (HQL). How to use HQL structure with hibernate query.
HQL: HQL means Hibernate Query Language. HQL supports object oriented query language. The syntax of HQL is very similar to SQL. HQL works with persistent objects to use java objects in place of SQL table and columns. When HQL is executed by hibernate and hql query converted into SQL queries.
If you want to use SQL statements with hibernate then use Native SQL. As we know that HQL is fully object oriented that's by use bean propertes in place of column name and class name for table.
There are following keywords to use HQL:
- ORDER BY
Above keywords are not case sensitive but HQL propertes and classes are fully case sensitive.