Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

What are batch updates. in jdbc

Answer Posted / vijayakumar chinnasamy

Batch Update provide the functionality of executing a group
of sql statement at single timing.

Steps:

1.set autocommit as false for connection .
connectionObject.setAutoCommit(false);
2.create sql statement and add to statement object.
statementObj.addBatch("sql1");
statementObj.addBatch("sql2");
statementObj.addBatch("sql3");
3.execute the batch of statement using executeBatch().
statementObj.executebatch();
4. commit the connection.
connectionObj.commit();

Is This Answer Correct ?    3 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is difference between overloading and overriding in java?

1079


Differentiate between a class and an object.

1070


What is substring 1 in java?

1235


How to make a write-only class in java?

1103


How to handle a web browser resize operation?

1133


What is the multi-catch block in java?

1101


What is immutable state?

1100


What is the type of lambda expression?

1087


Why is a string immutable?

1067


What is arrays aslist in java?

995


Does treeset allow null in java?

1007


What is data type in computer?

1001


What are methods?

1075


what is the difference between process and thread? : Java thread

1023


What is use of arraylist in java?

1241