Esta sección solo está disponible en inglés.

Variables and environments: The four types

Write {{name}} anywhere in a script. Substitution happens once, at pre-flight, before a singlestatement is sent.

Última actualización 2026-10-21

Write {{name}} anywhere in a script. Substitution happens once, at pre-flight, before a single statement is sent.

The variable editor: each variable declared once with its type, and a value for each environment.
The variable editor: each variable declared once with its type, and a value for each environment.

The type is on the declaration, so a script author does not decide quoting at every usage site.

Type Emits Use for
text A dialect-escaped string literal — an apostrophe is safe Values compared against a string column
identifier A dialect-quoted identifier Schema, table, or database names
number Validated as a number, emitted invariant. A non-number fails pre-flight Counts, thresholds, ids
raw Verbatim — the value becomes part of the SQL Genuine SQL fragments, and nothing else

raw is flagged at preview time:

This script substitutes values raw. Use |literal or |ident unless the value is meant to be SQL.