-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 
Author Message
 Post subject: virtually delete a record across the schema using hibernate
PostPosted: Mon Nov 10, 2008 5:27 pm 
Newbie

Joined: Mon Nov 10, 2008 5:22 pm
Posts: 2
Hi All,
I am trying to implement a virtual delete of records across all the tables in the schema using hibernate. To elaborate, there is never a physical delete in the table, its just a flag thats updated. Is there some configuration supported by hibernate to support this?
Your suggestions and answers are highly appreciated.
Thanks
Ashima


Top
 Profile  
 
 Post subject:
PostPosted: Tue Nov 11, 2008 3:07 pm 
Newbie

Joined: Mon Nov 10, 2008 5:22 pm
Posts: 2
I got an answer.
Hibernates (3.0 onwards) event model supports this. Just extend hibernate's DefaultEventListener class and register the event listner in your hibernate configuration file. POJO that needs to support soft delete must implement this Event .
Thanks
Ashima


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.