Here is the answer,
We can handle the transanction by using setAutoCommit() method. We use setAutoCommit() method because all the database transaction should be committed automatically by JDBC. JDBC takes default commit mode as true. true means transactions committed automatically.[you cannot roll back any database transaction].false means you can manipulate transaction yourself.
So we use this method commit mode as false.
The code is as follows-
Connection conn = getConnection(); conn.setAutocommit(false); //other code conn.commit(); conn.close();
If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.
Ask your questions, our development team will try to give answers to your questions.