pg_exec_prepared − send a request to execute a prepared SQL statement to the server
pg_exec_prepared conn statementName [args]
pg_exec_prepared submits a command to the PostgreSQL server and returns a result.
pg_exec_prepared functions identically to pg_exec, except that it operates using statements prepared by the PREPARE SQL command.
Note that prepared statements are only support under PostgreSQL 7.4 and later.
conn |
The handle of the connection on which to execute the command. |
statementName
The name of the prepared statement to execute.
args |
args consists of zero or more optional values that can be inserted, unquoted, into the SQL statement using $-style substitution. |
A result handle. See pg_exec for details.
pg_exec $conn
{prepare insert_people
(varchar, varchar, varchar, varchar, varchar, varchar)
as insert into people values ($1, $2, $3, $4, $5, $6);}
pg_exec_prepared $conn insert_people $email $name $address $city $state $zip