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

Popular posts from this blog

Javascript line number mapping -

c# - Is it possible to remove an existing registration from Autofac container builder? -

php - Mysql PK and FK char(36) vs int(10) -