This content has been marked as final.
Show 2 replies
-
1. Re: Using envers ... one step further -> 4 eye principle
bestage Jul 24, 2009 9:56 AM (in response to bestage)Small addition: my 2nd solution might be OK, if the access to the data is hidden behind an API. But what if another non-Java app needs this data and wants to access productive records. In that case one would need to make complex SQL queries (Union, etc) on both original / history table,
since one cannot rely only on teh original table. -
2. Re: Using envers ... one step further -> 4 eye principle
adamw Jul 27, 2009 2:40 PM (in response to bestage)Hello,
as I understand you want to get the newest revision of an entity which has a flag set to true. You can do this using a revision-of-entity query, by maximizing the revision number property (there's a special constraint for that), adding another constraint on the flag value.
Adam