ExecuteResult

data class ExecuteResult(val rowsAffected: Long, val lastInsertId: Long?)(source)

The outcome of a statement run with QueryExecutor.executeWithResult.

Constructors

Link copied to clipboard
constructor(rowsAffected: Long, lastInsertId: Long?)

Properties

Link copied to clipboard

The auto-generated id of the row inserted by the statement, when the database reports one: MySQL/MariaDB (LAST_INSERT_ID()) and SQLite (the rowid). It is null when the statement generated no id, and always on PostgreSQL, which has no such value: use INSERT ... RETURNING with fetchAll there. For a multi-row insert, MySQL reports the id of the first inserted row and SQLite the id of the last.

Link copied to clipboard

The number of rows inserted, updated or deleted.