1 of 1 people found this helpful
I think you do everything, except that you don't need to setDeletedEntites = true. All entities are always taken into account; this parameter only specifies if the "DEL" revisions (which have all-null) data should be returned. Otherwise, the last change of the entity will be returned.
Unless you want to get the revision at which the entity was deleted, not the revision at which the last change was made to it. If so, you'll have to upgrade to a newer version of Hibernate and set the conf parameter store data in delted revisions to true.
I want the version number of the latest change to the set of entities, which sometimes may be a delete.
Upgrading hibernate is not an option at this time so I'll just handle it with a native query.