skip to main content
Reference : Connection Property Descriptions : BatchMechanism
  

BatchMechanism

Purpose

Determines the mechanism that is used to execute batch operations.

Valid Values

nativeBatch | multiRowInsert

Behavior

If set to nativeBatch, the driver uses the data store's native batch mechanism to execute batch operations. NativeBatch returns individual update counts for each statement or parameter set in the batch.
If set to multiRowInsert, the driver uses a parameterized multi-row insert statement to execute batch inserts. MultiRowInsert returns only the total number of update counts in the batch, but provides substantial performance gains when performing batch inserts.

Notes

MultiRowInsert only applies to Insert statements for batch executes called with PreparedStatement objects. If a command other than the Insert statement is used, the driver uses the native batch mechanism to execute the command.

Default

multiRowInsert

Data Type

String

See also

*Batch Inserts and Updates
*Performance Considerations