Disable auto commit mode in JDBC
import java.sql.Connection; public class Main { public static void main(String[] args) throws Exception{ Connection connection = null; connection.setAutoCommit(false); connection.commit(); } }