A developer needs to insert multiple rows into a database efficiently. Which statement type and technique should they use?

  • Batch processing using PreparedStatement
  • Individual inserts using Statement
  • Stored Procedure with Cursor
  • Trigger for each row
Batch processing using a PreparedStatement is an efficient way to insert multiple rows into a database as it reduces the number of database round-trips. It allows the developer to group multiple SQL statements and execute them as a batch.
Add your answer
Loading...

Leave a comment

Your email address will not be published. Required fields are marked *