Skip to content

sqlQuery

sqlQuery<Predicate, Bound>(outcome, bindParameters, conditions?): object

Returns the search condition and bound parameters for one outcome.

The constant outcomes bind no parameter, so parameters is empty for them. Pass the parameter converter that the selected profile documents, which is postgreSqlParameters for PostgreSQL and parameterValues over the predicate’s parameters for every other SQL profile.

Predicate extends SqlPredicateShape

Bound

TranslationOutcome<Predicate>

Outcome that a translator produced.

(predicate) => Bound[]

Converter that the selected profile documents.

SqlOutcomeConditions = {}

Conditions substituted for the constant outcomes.

object

parameters: Bound[]

sql: string