pg_sendquery

Name

pg_sendquery -- send a query string to the backend connection without waiting for a result

Synopsis

pg_sendquery conn commandString

Description

pg_sendquery submits a command to the PostgreSQL server. This function works like pg_exec, except that it does not return a result. Rather, the command is issued to the backend asynchronously.

The result is either an error message or nothing. An empty return indicates that the command was dispatched to the backend.

Arguments

conn

The handle of the connection on which to execute the command.

commandString

The SQL command to execute.

Return Value

A Tcl error will be returned if pgtcl was unable to issue the command. Otherwise, an empty string will be return. It is up to the developer to use pg_getresult to obtain results from commands issued with pg_sendquery.