What is the purpose of setAutoCommit() ?



What is the purpose of setAutoCommit() ?..

Answer / shahnawaz sheikh

If AutoCommit is off, then any update or insert operation
perforned on database will not be reflected just after the
query is executed.Though the operation has been
successfully completed.
We will have to commit the transaction manually, to view
the incurred changes.
This also keeps user on the safer side, if some
undesirable row has been inserted,updated or deleted in the
database then it can be rollback.

While if the AutoCommit is on any update,insert or delete
are at once reflected onto the database.

Is This Answer Correct ?    13 Yes 1 No

Post New Answer

More Core Java Interview Questions

can we have virtual functions in java?

11 Answers   Wipro,


How do you find the independent variable?

0 Answers  


What is nested interface?

0 Answers  


What is the difference between this() and super()?

15 Answers   TCS,


What is run-time class and system class? what is their purpose?

1 Answers  






Why is whitespace important?

0 Answers  


Why Java is called as purely platform independent..? Explain briefly..dont Give regular answers Explain with your own example..?

8 Answers   Nokia,


Explain how hashmap works?

0 Answers  


Is string is a data type?

0 Answers  


Explain the relationship between the Canvas and Graphics class?

1 Answers  


Is it compulsory for a try block to be followed by a catch block in java for exception handling?

0 Answers  


How to use string tokenizer class.

0 Answers  


Categories