Development snapshot. PostgreSQL 20devel has not been released. Content may change.
VAR
VAR — define a variable
Synopsis
VARvarnameISctype
Description
The VAR command assigns a new C data type
to a host variable. The host variable must be previously
declared in a declare section.
Examples
Exec sql begin declare section; short a; exec sql end declare section; EXEC SQL VAR a IS int;
Compatibility
The VAR command is a PostgreSQL extension.
Report a documentation issue
Read the upstream documentation. For corrections, first check the current manual.