How to map a read only property backed by a query in Hibernate
I'm wondering how to best implement a property (here, LatestRequest) which is read-only, backed by a query. Here, I have an Export, which can be requested to happen multiple times. I'd like to have a property on the Export to get the latest ExportRequest. At the moment, I've got a many-to-one mapping with a formula, like this: <class ...