Abby
01/31/2020, 4:14 PMtapac
02/04/2020, 5:46 PMfun main() {
//...
transaction.exec(PragmaStatement("automatic_index"))
}
class PragmaStatement(val value: String) : Statement<Unit>(StatementType.OTHER, emptyList()) {
override fun arguments(): Iterable<Iterable<Pair<IColumnType, Any?>>> = emptyList()
override fun prepareSQL(transaction: Transaction): String = "PRAGMA $value"
override fun PreparedStatement.executeInternal(transaction: Transaction): Unit? {
this.executeUpdate()
return null
}
}
Abby
02/04/2020, 7:12 PM