orm - Multiple record deletion using hibernate -
what best way delete multiple records using hibernate.my requirement getting list of uuids , based on need remove records database.
since hibernate not have build in delete method can take collection input , work on behalf of us.
so looking best possible way achieve this. not going bulk delete option since number of records not gooing high , nor using spring's template has support type of operation.
thanks in advance umesh
two options come mind:
- fetch records , call
session.delete(..)
on each entity - use hql
delete
, clause. have in mind cascades won't handled.
Comments
Post a Comment