docs/api/exposed-r2dbc/org.jetbrains.exposed.v1.r2dbc/index.html
TypesFunctionsProperties
Link copied to clipboard
class EmptySizedIterable<out T> : SizedIterable<T>
Represents a SizedIterable that is empty and cannot be iterated over.
Link copied to clipboard
class Except(firstStatement: AbstractQuery<*>, secondStatement: AbstractQuery<*>) : SetOperation
Represents an SQL operation that returns the distinct results of firstStatement that are not common to secondStatement.
Link copied to clipboard
open class ExplainSuspendExecutable(val statement: ExplainQuery) : SuspendExecutable<ResultApi, ExplainQuery> , Flow<ExplainResultRow>
Represents the execution logic for an SQL statement that obtains information about a statement execution plan.
Link copied to clipboard
class ExposedR2dbcException(cause: Throwable?, val contexts: List<StatementContext>, transaction: R2dbcTransaction) : R2dbcException
An exception that provides information about a database access error, within the contexts of the executed statements that caused the exception.
Link copied to clipboard
class Intersect(firstStatement: AbstractQuery<*>, secondStatement: AbstractQuery<*>) : SetOperation
Represents an SQL operation that returns only the common rows from two query results, without any duplicates.
Link copied to clipboard
class LazySizedCollection<out T>(_delegate: SizedIterable<T>) : SizedIterable<T>
Represents a SizedIterable whose elements are only loaded on first access.
Link copied to clipboard
interface LazySizedIterable<T> : SizedIterable<T>
Represents the iterable elements of a database result, which are stored once loaded on first access.
Link copied to clipboard
open class Query(var set: FieldSet, where: Op<Boolean>?) : AbstractQuery<Query> , SuspendExecutable<ResultApi, Query> , SizedIterable<ResultRow>
Class representing an SQL SELECT statement on which query clauses can be built.
Link copied to clipboard
class R2dbcDatabase : DatabaseApi
Class representing the underlying R2DBC database to which connections are made and on which transaction tasks are performed.
Link copied to clipboard
interface R2dbcDatabaseConfig : DatabaseConfig
A configuration for an R2dbcDatabase instance.
Link copied to clipboard
open class R2dbcTransaction(transactionImpl: R2dbcTransactionInterface) : Transaction, R2dbcTransactionInterface
Class representing a unit block of work that is performed on a database using an R2DBC driver.
Link copied to clipboard
object SchemaUtils : SchemaUtilityApi
Utility functions that assist with creating, altering, and dropping database schema objects.
Link copied to clipboard
sealed class SetOperation : AbstractQuery<SetOperation> , SuspendExecutable<ResultApi, SetOperation> , SizedIterable<ResultRow>
Represents an SQL operation that combines the results of multiple queries into a single result.
Link copied to clipboard
class SizedCollection<out T>(val delegate: Collection<T>) : SizedIterable<T>
Represents a SizedIterable that defers to the specified delegate collection.
Link copied to clipboard
interface SizedIterable<out T> : Flow<T>
Represents the iterable elements of a database result.
Link copied to clipboard
class Union(firstStatement: AbstractQuery<*>, secondStatement: AbstractQuery<*>) : SetOperation
Represents an SQL operation that combines all results from two queries, without any duplicates.
Link copied to clipboard
class UnionAll(firstStatement: AbstractQuery<*>, secondStatement: AbstractQuery<*>) : SetOperation
Represents an SQL operation that combines all results from two queries, with duplicates included.
Link copied to clipboard
val ConnectionFactoryOptions.dialect: VendorDialect.DialectNameProvider
Returns the exact VendorDialect used by this ConnectionFactoryOptions state holder.
Link copied to clipboard
val ConnectionFactoryOptions.dialectName: String
Returns the string VendorDialect name used by this ConnectionFactoryOptions state holder.
Link copied to clipboard
val R2dbcDatabase.name: String
Returns the name of the database obtained from its connection URL.
Link copied to clipboard
val ConnectionFactoryOptions.urlString: String
Returns the constructed url connection string used by this ConnectionFactoryOptions state holder.
Link copied to clipboard
fun Query.andHaving(andPart: () -> Op<Boolean>): Query
Mutate Query instance and add andPart to having condition with and operator.
Link copied to clipboard
fun Query.andWhere(andPart: () -> Op<Boolean>): Query
Mutate Query instance and add andPart to where condition with and operator.
Link copied to clipboard
suspend fun <T : Table, E> T.batchInsert(data: Iterable<E>, ignore: Boolean = false, shouldReturnGeneratedValues: Boolean = true, body: BatchInsertStatement.(E) -> Unit): List<ResultRow>
suspend fun <T : Table, E> T.batchInsert(data: Sequence<E>, ignore: Boolean = false, shouldReturnGeneratedValues: Boolean = true, body: BatchInsertStatement.(E) -> Unit): List<ResultRow>
Represents the SQL statement that batch inserts new rows into a table.
Link copied to clipboard
suspend fun <T : Table, E : Any> T.batchReplace(data: Iterable<E>, shouldReturnGeneratedValues: Boolean = true, body: BatchReplaceStatement.(E) -> Unit): List<ResultRow>
suspend fun <T : Table, E : Any> T.batchReplace(data: Sequence<E>, shouldReturnGeneratedValues: Boolean = true, body: BatchReplaceStatement.(E) -> Unit): List<ResultRow>
Represents the SQL statement that either batch inserts new rows into a table, or, if insertions violate unique constraints, first deletes the existing rows before inserting new rows.
Link copied to clipboard
suspend fun <T : Table, E : Any> T.batchUpsert(data: Iterable<E>, vararg keys: Column<*>, onUpdate: UpsertBuilder.(UpdateStatement) -> Unit? = null, onUpdateExclude: List<Column<*>>? = null, where: () -> Op<Boolean>? = null, shouldReturnGeneratedValues: Boolean = true, body: BatchUpsertStatement.(E) -> Unit): List<ResultRow>
suspend fun <T : Table, E : Any> T.batchUpsert(data: Sequence<E>, vararg keys: Column<*>, onUpdate: UpsertBuilder.(UpdateStatement) -> Unit? = null, onUpdateExclude: List<Column<*>>? = null, where: () -> Op<Boolean>? = null, shouldReturnGeneratedValues: Boolean = true, body: BatchUpsertStatement.(E) -> Unit): List<ResultRow>
Represents the SQL statement that either batch inserts new rows into a table, or updates the existing rows if insertions violate unique constraints.
Link copied to clipboard
suspend fun Join.delete(targetTable: Table, vararg targetTables: Table, ignore: Boolean = false, limit: Int? = null): Int
Represents the SQL statement that deletes all rows from a table in a join relation.
suspend fun Join.delete(targetTable: Table, vararg targetTables: Table, ignore: Boolean = false, limit: Int? = null, where: () -> Op<Boolean>): Int
Represents the SQL statement that deletes rows from a table in a join relation.
Link copied to clipboard
suspend fun Table.deleteAll(): Int
Represents the SQL statement that deletes all rows in a table.
Link copied to clipboard
suspend fun <T : Table> T.deleteIgnoreWhere(limit: Int? = null, op: T.() -> Op<Boolean>): Int
Represents the SQL statement that deletes only rows in a table that match the provided op, while ignoring any possible errors that occur during the process.
Link copied to clipboard
fun <T : Table> T.deleteReturning(returning: List<Expression<*>> = columns): ReturningSuspendExecutable
Represents the SQL statement that deletes all rows in a table and returns specified data from the deleted rows.
fun <T : Table> T.deleteReturning(returning: List<Expression<*>> = columns, where: () -> Op<Boolean>): ReturningSuspendExecutable
Represents the SQL statement that deletes rows in a table and returns specified data from the deleted rows.
Link copied to clipboard
suspend fun <T : Table> T.deleteWhere(limit: Int? = null, op: T.() -> Op<Boolean>): Int
Represents the SQL statement that deletes only rows in a table that match the provided op.
Link copied to clipboard
fun <T> emptySized(): SizedIterable<T>
Returns an EmptySizedIterable.
Link copied to clipboard
fun AbstractQuery<*>.except(other: Query): Except
Returns only distinct results from this query that are NOT common to the results of other.
Link copied to clipboard
suspend fun Schema.exists(): Boolean
Checks if this schema exists or not.
suspend fun Sequence.exists(): Boolean
Returns whether this sequence exists in the database.
suspend fun Table.exists(): Boolean
Returns whether this table exists in the database.
Link copied to clipboard
fun R2dbcTransaction.explain(analyze: Boolean = false, options: String? = null, body: StatementBuilder.() -> Statement<*>): ExplainSuspendExecutable
Creates an ExplainQuery using the EXPLAIN keyword, which obtains information about a statement execution plan.
Link copied to clipboard
suspend fun <T : Table> T.insert(body: T.(InsertStatement<Number>) -> Unit): InsertStatement<Number>
Represents the SQL statement that inserts a new row into a table.
suspend fun <T : Table> T.insert(selectQuery: AbstractQuery<*>, columns: List<Column<*>>? = null): InsertSelectStatement
Represents the SQL statement that uses data retrieved from a selectQuery to insert new rows into a table.
Link copied to clipboard
suspend fun <Key : Any, T : IdTable<Key>> T.insertAndGetId(body: T.(InsertStatement<EntityID<Key>>) -> Unit): EntityID<Key>
Represents the SQL statement that inserts a new row into a table.
Link copied to clipboard
suspend fun <T : Table> T.insertIgnore(body: T.(UpdateBuilder<*>) -> Unit): InsertStatement<Long>
Represents the SQL statement that inserts a new row into a table, while ignoring any possible errors that occur during the process.
suspend fun <T : Table> T.insertIgnore(selectQuery: AbstractQuery<*>, columns: List<Column<*>>? = null): Int?
Represents the SQL statement that uses data retrieved from a selectQuery to insert new rows into a table, while ignoring any possible errors that occur during the process.
Link copied to clipboard
suspend fun <Key : Any, T : IdTable<Key>> T.insertIgnoreAndGetId(body: T.(UpdateBuilder<*>) -> Unit): EntityID<Key>?
Represents the SQL statement that inserts a new row into a table, while ignoring any possible errors that occur during the process.
Link copied to clipboard
fun <T : Table> T.insertReturning(returning: List<Expression<*>> = columns, ignoreErrors: Boolean = false, body: T.(InsertStatement<Number>) -> Unit): ReturningSuspendExecutable
Represents the SQL statement that inserts new rows into a table and returns specified data from the inserted rows.
Link copied to clipboard
fun AbstractQuery<*>.intersect(other: Query): Intersect
Returns only results from this query that are common to the results of other, WITHOUT including any duplicates.
Link copied to clipboard
infix fun <T, R> SizedIterable<T>.mapLazy(f: (T) -> R): SizedIterable<R>
Returns a SizedIterable containing the lazily evaluated results of applying the function f to each original element.
Link copied to clipboard
suspend fun <D : Table, S : Table> D.mergeFrom(source: S, body: MergeTableStatement.() -> Unit): MergeTableStatement
suspend fun <D : Table, S : Table> D.mergeFrom(source: S, on: () -> Op<Boolean>, body: MergeTableStatement.() -> Unit): MergeTableStatement
Performs an SQL MERGE operation to insert, update, or delete records in the target table based on a comparison with a source table.
suspend fun <T : Table> T.mergeFrom(selectQuery: QueryAlias, on: () -> Op<Boolean>, body: MergeSelectStatement.() -> Unit): MergeSelectStatement
Performs an SQL MERGE operation to insert, update, or delete records in the target table based on a comparison with a select query source.
Link copied to clipboard
fun Query.orHaving(orPart: () -> Op<Boolean>): Query
Mutate Query instance and add orPart to having condition with or operator.
Link copied to clipboard
fun Query.orWhere(orPart: () -> Op<Boolean>): Query
Mutate Query instance and add orPart to where condition with or operator.
Link copied to clipboard
suspend fun <T : Table> T.replace(body: T.(UpdateBuilder<*>) -> Unit): ReplaceStatement<Long>
Represents the SQL statement that either inserts a new row into a table, or, if insertion would violate a unique constraint, first deletes the existing row before inserting a new row.
suspend fun <T : Table> T.replace(selectQuery: AbstractQuery<*>, columns: List<Column<*>>? = null): Int?
Represents the SQL statement that uses data retrieved from a selectQuery to either insert a new row into a table, or, if insertion would violate a unique constraint, first delete the existing row before inserting a new row.
Link copied to clipboard
fun ColumnSet.select(columns: List<Expression<*>>): Query
Creates a SELECT Query using a list of columns or expressions from this ColumnSet.
fun ColumnSet.select(column: Expression<*>, vararg columns: Expression<*>): Query
Creates a SELECT Query by selecting either a single column, or a subset of columns, from this ColumnSet.
Link copied to clipboard
fun FieldSet.selectAll(): Query
Creates a SELECT Query by selecting all columns from this ColumnSet.
Link copied to clipboard
fun AbstractQuery<*>.union(other: Query): Union
Combines all results from this query with the results of other, WITHOUT including duplicates.
Link copied to clipboard
fun AbstractQuery<*>.unionAll(other: Query): UnionAll
Combines all results from this query with the results of other, WITH duplicates included.
Link copied to clipboard
suspend fun <T : Table> T.update(limit: Int? = null, body: T.(UpdateStatement) -> Unit): Int
Represents the SQL statement that updates all rows of a table.
suspend fun Join.update(limit: Int? = null, body: (UpdateStatement) -> Unit): Int
Represents the SQL statement that updates all rows of a join relation.
suspend fun <T : Table> T.update(where: () -> Op<Boolean>, limit: Int? = null, body: T.(UpdateStatement) -> Unit): Int
Represents the SQL statement that updates rows of a table.
suspend fun Join.update(where: () -> Op<Boolean>, limit: Int? = null, body: (UpdateStatement) -> Unit): Int
Represents the SQL statement that updates rows of a join relation.
Link copied to clipboard
fun <T : Table> T.updateReturning(returning: List<Expression<*>> = columns, body: T.(UpdateStatement) -> Unit): ReturningSuspendExecutable
Represents the SQL statement that updates all rows of a table and returns specified data from the updated rows.
fun <T : Table> T.updateReturning(returning: List<Expression<*>> = columns, where: () -> Op<Boolean>, body: T.(UpdateStatement) -> Unit): ReturningSuspendExecutable
Represents the SQL statement that updates rows of a table and returns specified data from the updated rows.
Link copied to clipboard
suspend fun <T : Table> T.upsert(vararg keys: Column<*>, onUpdate: UpsertBuilder.(UpdateStatement) -> Unit? = null, onUpdateExclude: List<Column<*>>? = null, where: () -> Op<Boolean>? = null, body: T.(UpsertStatement<Long>) -> Unit): UpsertStatement<Long>
Represents the SQL statement that either inserts a new row into a table, or updates the existing row if insertion would violate a unique constraint.
Link copied to clipboard
fun <T : Table> T.upsertReturning(vararg keys: Column<*>, returning: List<Expression<*>> = columns, onUpdate: UpsertBuilder.(UpdateStatement) -> Unit? = null, onUpdateExclude: List<Column<*>>? = null, where: () -> Op<Boolean>? = null, body: T.(UpsertStatement<Long>) -> Unit): ReturningSuspendExecutable
Represents the SQL statement that either inserts a new row into a table, or updates the existing row if insertion would violate a unique constraint, and also returns specified data from the modified rows.
Generated by Dokka © 2026 Copyright