public class BatchQuery extends Object
| Constructor and Description |
|---|
BatchQuery(String driverName,
String connectionString,
String sql,
int recordsPerPart)
Creates a new
BatchQuery |
| Modifier and Type | Method and Description |
|---|---|
void |
addBatch(String... fields)
Executes the provided query
|
void |
executeBatch() |
public BatchQuery(String driverName, String connectionString, String sql, int recordsPerPart) throws Exception
BatchQuerydriverName - The name of the driverconnectionString - The connection stringsql - The SQL query for prepared statementrecordsPerPart - The number of records to put in each partException - An unrecoverable for the operation error occuredpublic void addBatch(String... fields) throws Exception
fields - the updated fieldsException - An unrecoverable for the operation error occuredpublic void executeBatch()
throws SQLException
SQLExceptionCopyright © 2017. All Rights Reserved.