skip to main content
Supported Features : Using Arrays of Parameters
  

Try DataDirect Drivers Now

Using Arrays of Parameters

By default, the driver supports multi-row inserts for parameterized arrays. For a multi-row insert, the driver attempts to execute a single insert for all the rows contained in a parameter array. If the size of the insert statement exceeds the available buffer memory of the driver, the driver executes multiple statements. This behavior provides substantial performance gains for batch inserts.
The driver modifies the HQL statement to perform a multi-row insert. Therefore, the default multi-row insert behavior may not be desirable in all scenarios. You can disable this behavior by setting the Batch Mechanism connection option to 1 (SingleInsert). When BatchMechanism=1, the driver's batch mechanism emulation is used to execute batch operations, and an insert statement is executed for each row contained in a parameter array.
Refer to "Designing ODBC Applications for Performance Optimization" for more information about using arrays of parameters to improve performance.