What is Batch Update in JDBC?

  • When we want to submit multiple queries to Database one by one a lot time will wasted for the request and response.
  • Instead of submitting SQL statement one by one we can submit multiple statement once to Database as a batch using batch update concept.
  • To implement Batch Update, we can use the following method of statement interface:
                 void addBatch(SQLstatement );
                    int[] executeBatch();
  • Using Batach Update we can submit multiple insert, update, delete statement.

0 comments :

Post a Comment