batch
Transacts to the database in exclusive mode a batch of queries with the same underlying SQL statement. The prototypical use case is for database modifications inside a tight loop to which this is optimised.
Each array in the sequence must have the same length, corresponding to the number of arguments in the SQL statement. It is safe for the sequence to recycle the array with each yield.
The transaction is not committed by this method until the sequence ends. For long sequences you may therefore wish to yield the transaction periodically.
Return
the number of rows affected.
Parameters
sql
statement.
bindArgs
sequence of standard type arguments for binding to the statement.