127 "block_size":
sprintf(
"the row block size used for bulk DML / batch operations; default: %y",
OptionDefaults.block_size),
128 "info_log":
"a call reference / closure for informational logging",
552 setupStaticRowValues(reference<hash> row);
hash cval
"constant" row values; must be equal in all calls to queueData
Definition: BulkSqlUtil.qm.dox.h:149
*code info_log
an optional info logging callback; must accept a sprintf()-style format specifier and optional argume...
Definition: BulkSqlUtil.qm.dox.h:155
constructor(SqlUtil::Table target, *hash opts)
creates the object from the supplied arguments
SqlUtil::AbstractTable getTable()
returns the underlying SqlUtil::AbstractTable object
string sprintf(string fmt,...)
constructor(SqlUtil::Table target, *hash opts)
creates the object from the supplied arguments
flushImpl()
executes bulk DML upserts in the database with internally queued data
Qore::SQL::AbstractDatasource getDatasource()
returns the AbstractDatasource object associated with this object
abstract flushImpl()
flushes queued data to the database
queueData(hash data)
queues row data in the block buffer; the block buffer is flushed to the DB if the buffer size reaches...
discard()
discards any buffered batched data; this method should be called before destroying the object if an e...
setupInitialRow(hash row)
sets up the block buffer given the initial template row for inserting
setupInitialRow(hash row)
sets up support for "returning" insert options for any possible rowcode member
int row_count
row count
Definition: BulkSqlUtil.qm.dox.h:158
base class for bulk DML upsert operations
Definition: BulkSqlUtil.qm.dox.h:619
setupInitialRowColumns(hash row)
sets up the block buffer given the initial template hash of lists for inserting
const OptionKeys
option keys for this object
Definition: BulkSqlUtil.qm.dox.h:126
the BulkSqlUtil namespace contains all the definitions in the BulkSqlUtil module
Definition: BulkSqlUtil.qm.dox.h:70
string getTableName()
returns the table name
hash static_ret_expr
hash of "returning" arguments
Definition: BulkSqlUtil.qm.dox.h:472
setRowCode(*code rowc)
sets a closure or call reference that will be called when data has been sent to the database and all ...
flushIntern()
flushes queued data to the database
init(*hash opts)
common constructor initialization
SQLStatement stmt
statement for DML
Definition: BulkSqlUtil.qm.dox.h:466
base class for bulk DML insert operations
Definition: BulkSqlUtil.qm.dox.h:461
nothing rollback()
discards any queued data and rolls back the transaction
constructor(string name, SqlUtil::Table target, *hash opts)
creates the object from the supplied arguments
int getRowCount()
returns the affected row count
string opname
operation name
Definition: BulkSqlUtil.qm.dox.h:161
setupInitialRowColumns(hash row)
sets up the block buffer given the initial template hash of lists for inserting
nothing commit()
flushes any queued data and commits the transaction
SqlUtil::AbstractTable table
the target table object
Definition: BulkSqlUtil.qm.dox.h:140
*code rowcode
per-row Closures or Call References for inserts
Definition: BulkSqlUtil.qm.dox.h:469
destructor()
throws an exception if there is data pending in the internal row data cache; make sure to call flush(...
const OptionDefaults
default option values
Definition: BulkSqlUtil.qm.dox.h:132
list cval_keys
"constant" row value keys
Definition: BulkSqlUtil.qm.dox.h:152
flushImpl()
inserts internally-queued queued data in the database with bulk DML operations
flush()
flushes any remaining batched data to the database; this method should always be called before commit...
base class for bulk DML operations
Definition: BulkSqlUtil.qm.dox.h:121
list ret_args
list of "returning" columns
Definition: BulkSqlUtil.qm.dox.h:164
init(*hash opts)
common constructor initialization
int size()
returns the current size of the cache as a number of rows
hash hbuf
buffer for bulk operations
Definition: BulkSqlUtil.qm.dox.h:146
init(*hash opts)
common constructor initialization
softint block_size
bulk operation block size
Definition: BulkSqlUtil.qm.dox.h:143