forEachRow

fun forEachRow(params: Map<String, Any?> = emptyMap(), fetchSize: Int, block: (Row) -> Unit)

Runs the query and hands each row to block as it arrives, so a result too large to hold is streamed. block runs while the result is still being read, and a query from inside it is refused with CONNECTION_BUSY.

Parameters

fetchSize

Rows per batch, or 0 for the whole result in one Execute.


fun forEachRow(vararg params: Pair<String, Any?>, fetchSize: Int, block: (Row) -> Unit)

Runs the query and hands each row to block as it arrives, in batches of fetchSize.