When writing HQL queries, join clauses are often necessary to optimise the query using a "left join fetch" clause, as in the following example (I discuss this type of optimisation in another article.)
from Sale sale
where sale.date > :startDate
left join fetch sale.product
When using the criteria API, you can do the same thing using the setFetchMode() function :