ExplainQuery

open class ExplainQuery(val analyze: Boolean, val options: String?, internalStatement: Statement<*>) : Statement<ResultSet> , Iterable<ExplainResultRow>

Represents the SQL query that obtains information about a statement execution plan.

Parameters

analyze

Whether the statement whose execution plan is being queried should actually be executed as well.

options

String of comma-separated parameters to append after the EXPLAIN keyword.

Constructors

Link copied to clipboard
constructor(analyze: Boolean, options: String?, internalStatement: Statement<*>)

Properties

Link copied to clipboard
Link copied to clipboard

Whether the SQL statement is meant to be performed as part of a batch execution.

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

Functions

Link copied to clipboard
fun <T> Iterable<T>.appendTo(builder: QueryBuilder, separator: CharSequence = ", ", prefix: CharSequence = "", postfix: CharSequence = "", transform: QueryBuilder.(T) -> Unit): QueryBuilder

Appends all the elements separated using separator and using the given prefix and postfix if supplied.

Link copied to clipboard
open override fun arguments(): Iterable<Iterable<Pair<IColumnType<*>, Any?>>>

Returns all mappings of columns and expression types to their values needed to prepare an SQL statement.

Link copied to clipboard
fun execute(transaction: Transaction): ResultSet?

Executes the SQL statement directly in the provided transaction and returns the generated result, or null if either no result was retrieved or if the transaction blocked statement execution.

Link copied to clipboard

Determines the exact way that an SQL statement is executed in a transaction and applies any necessary logic before returning the result generated by the executed statement.

Link copied to clipboard
Link copied to clipboard
open operator override fun iterator(): Iterator<ExplainResultRow>
Link copied to clipboard
open fun prepared(transaction: Transaction, sql: String): PreparedStatementApi

Uses a transaction connection and an sql string representation to return a precompiled SQL statement, stored as an implementation of PreparedStatementApi.

Link copied to clipboard
open override fun prepareSQL(transaction: Transaction, prepared: Boolean): String

Returns the string representation of an SQL statement.

Link copied to clipboard