RawQuery
SQL written by hand, with @name parameters, carrying the same terminal methods every builder carries.
What separates it from the builders is not reach. Every clause they take is SQL and is passed through, so a lateral join goes in from, a window function or DISTINCT ON in select, and recursive() is declared on all four of them - there is not much they cannot say. What they do is the mechanical part: the keywords and their order, the column list paired with its own placeholders, and the clauses that disappear when they have nothing to say. This is for the statement you would rather write whole - one that already exists, one that came from somewhere else, or one that assembling a clause at a time buys nothing.
It is also the only query with an execute, which is a different protocol rather than another terminal: DDL, SET and several statements in one round trip live here because no builder can reach them.
The SQL it was given comes back out of toSql like any other query's, rather than through a property of its own.
Properties
Functions
Switches this query to the result style: every terminal on the returned object hands back a DataResult instead of throwing.
Turns this query into a step of a TransactionPlan instead of something to run now.
Carries registered converters into a builder's copy(), alongside whatever clauses it copies.
As fetchField, but the query must return exactly one row rather than at most one.
Runs the query and returns its single row, throwing where the count was anything but one.
Builds the driver query a terminal is about to run, with this query's own converters on it.
Registers a ParameterConverter for this query and nothing else.
Registers a ResultConverter for this query and nothing else.