This content has been marked as final.
Show 3 replies
-
1. Re: Deleting an entity - Bug?
adamw Jan 6, 2009 10:08 AM (in response to kaizersh)Hello,
when you delete an entity, only the id, revision number and revision type fields won't be null. All the rest will be. That's because a row in the audit tables contains the *new* data of the entity - and when you delete, there's no new data.
The last data of the entity is of course not lost, you can find it in the last revision the entity was modified (or created)
--
Adam -
2. Re: Deleting an entity - Bug?
kaizersh Jan 7, 2009 4:25 AM (in response to kaizersh)Hi,
In our case, even our Audit Tables have Not Null constraints and we actually store the last data in the audit table. Is there some way I can achieve this with Envers? One way would be to override the postDelete method in my Listener class and change the DelWorkUnit accordingly.
Thanks.
Regards
Kaizer -
3. Re: Deleting an entity - Bug?
adamw Jan 8, 2009 4:20 PM (in response to kaizersh)Well, that's exactly the way to do it :)
--
Adam