How to delete List of different tablerecords from a single query in JOOQ? Is this possible with JOOQ API? Or i have to delete record one by one ,Just get one record fire query and so on?
For Ex: I have two records of different tables Like :
MyTableRecord1 and MyTableRecord2
I want to delete List of records from these two tables in a single call.
Yes, use DSLContext.batchDelete()
DSL.using(configuration)
.batchDelete(record1, record2)
.execute();
It'll generate JDBC batch statements for "similar" delete statements. If you're deleting from two tables, one record each, this will just generate two different delete statements.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With