Problem
We want a collection field belonging to an entity object to be sorted.
Solution
There are two possible solutions:
Remarks
- There exists an annotation with name
OrderBy in both the javax.persistence package as well as the org.hibernate.annotations package. The former should be used.