Skip to main content
Version: 1.0.16

CALL

CALL — Invoke a Procedure

Synopsis

CALL name ( [ argument ] [, ...] )

Description

CALL executes a procedure.

If the procedure has any output parameters, a result row will be returned containing the values of those parameters.

Parameters

name

The name (optionally schema-qualified) of the procedure.

argument

An input argument for the procedure call. For full details on function and procedure call syntax, including the use of arguments.

Notes

The user must have EXECUTE privilege on the procedure to call it.

To call a function (not a procedure), use SELECT instead.

If CALL is executed within a transaction block, the called procedure cannot execute transaction control statements. Transaction control statements are only allowed in procedures when CALL is executed in its own transaction.

PL/pgSQL handles output parameters in CALL differently.

Examples

CALL do_db_maintenance();

See Also

CREATE PROCEDURE