add Connection.selectAny()

This commit is contained in:
2023-04-05 23:12:08 +02:00
parent 90d5f6e0d7
commit 79d2e52978
5 changed files with 33 additions and 1 deletions

View File

@@ -67,6 +67,12 @@ class Query(override val name: String, private val sql: String, override val con
): Paginated<R> =
connection.select(sql, page, limit, typeReference, values, block)
override fun <R> selectAny(
typeReference: TypeReference<R>,
values: Map<String, Any?>,
block: QueryResult.(R) -> Unit
): R = connection.selectAny(sql, typeReference, values.toMap(), block)
/* Execute function without treatments */
override fun exec(values: List<Any?>): QueryResult = connection.exec(sql, values)