9. A Look at HQL

HQL queries have already been used a few times in previous chapters. It's worth spending a little time looking at how HQL differs from SQL and some of the useful things you can do with it. As with the rest of this notebook, our intention is to provide a useful introduction and some examples, not a comprehensive reference.

In this chapter:

  • Writing HQL Queries

  • Selecting Properties and Pieces

  • Sorting

  • Working with Aggregate Values

  • Writing Native SQL Queries

Get Hibernate: A Developer's Notebook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.