Search PostgreSQL documentation
PG 18 · Browse by category, or enter a name or keyword
Category index4025
Retrieving Other Result Information32.3.3. Retrieving Other Result Information
These functions are used to extract other information from PGresult objects.
PQcmdStatus # Returns the command status tag from the SQL command tha…Retrieving Other Result Information
Retrieving Query Result Information32.3.2. Retrieving Query Result Information
These functions are used to extract information from a PGresult object that represents a successful query result (that is, one that has status PGR…Retrieving Query Result Information
Retrieving Query Results34.4.3. Retrieving Query Results
Now you should be able to pass data generated by your program into an SQL command. But how do you retrieve the results of a query? For that purpose, embedded…Retrieving Query Results
Retrieving Query Results in Chunks32.6. Retrieving Query Results in Chunks
Ordinarily, libpq collects an SQL command's entire result and returns it to the application as a single PGresult. This can be unworkable for commands…Retrieving Query Results in Chunks
RETURN41.6.1.1. RETURN
RETURN expression;
RETURN with an expression terminates the function and returns the value of expression to the caller. This form is used for PL/pgSQL functions that do not …RETURN
RETURN NEXT and RETURN QUERY41.6.1.2. RETURN NEXT and RETURN QUERY
RETURN NEXT expression; RETURN QUERY query; RETURN QUERY EXECUTE command-string [ USING expression [, ... ] ];
When a PL/pgSQL function is declared to …RETURN NEXT and RETURN QUERY
Return ValueReturn Value
Returns the requested SQL statement as text.Return Value
Return ValueReturn Value
Returns the requested SQL statement as text.Return Value
Return ValueReturn Value
Returns the requested SQL statement as text.Return Value
Return ValueReturn Value
Returns OK if the cancel request has been sent, or the text of an error message on failure.Return Value
Return ValueReturn Value
Returns status, either OK or ERROR.Return Value
Return ValueReturn Value
Returns status, which is always OK (since any error causes the function to throw an error instead of returning).Return Value
Return ValueReturn Value
Returns status, which is always OK (since any error causes the function to throw an error instead of returning).Return Value
Return ValueReturn Value
Returns last error message, or OK if there has been no error in this connection.Return Value
Return ValueReturn Value
Returns status, either the command's status string or ERROR.Return Value
Return ValueReturn Value
The function returns the row(s) fetched from the cursor. To use this function, you will need to specify the expected set of columns, as previously discussed for dblink.Return Value
Return ValueReturn Value
The function returns the row(s) produced by the query. Since dblink can be used with any query, it is declared to return record, rather than specifying any particular set of col…Return Value
Return ValueReturn Value
Returns a text array of connection names, or NULL if none.Return Value
Return ValueReturn Value
Returns setof (notify_name text, be_pid int, extra text), or an empty set if none.Return Value
Return ValueReturn Value
Returns one row for each primary key field, or no rows if the relation has no primary key. The result row type is defined as
CREATE TYPE dblink_pkey_results AS (position int, co…Return Value
Return ValueReturn Value
For an async query (that is, an SQL statement returning rows), the function returns the row(s) produced by the query. To use this function, you will need to specify the expected…Return Value
Return ValueReturn Value
Returns 1 if connection is busy, 0 if it is not busy. If this function returns 0, it is guaranteed that dblink_get_result will not block.Return Value
Return ValueReturn Value
Returns status, either OK or ERROR.Return Value
Return ValueReturn Value
Returns 1 if the query was successfully dispatched, 0 otherwise.Return Value
Return ValueReturn Value
pointer to new storage space of specified size with the contents copied from the existing areaReturn Value
Return ValueReturn Value
SPI_OK_CONNECT on success
The fact that these functions return int not void is historical. All failure cases are reported via ereport or elog. (In versions before PostgreSQL v10…Return Value
Return ValueReturn Value
the copied row, or NULL on error (see SPI_result for an error indication)Return Value
Return ValueReturn Value
SPI_processed and SPI_tuptable are set as in SPI_execute if successful.Return Value
Return ValueReturn Value
pointer to the portal with the specified name, or NULL if none was foundReturn Value
Return ValueReturn Value
Pointer to portal containing the cursor. Note there is no error return convention; any error will be reported via elog.Return Value
Return ValueReturn Value
Pointer to portal containing the cursor. Note there is no error return convention; any error will be reported via elog.Return Value
Return ValueReturn Value
Pointer to portal containing the cursor. Note there is no error return convention; any error will be reported via elog.Return Value
Return ValueReturn Value
Pointer to portal containing the cursor. Note there is no error return convention; any error will be reported via elog.Return Value
Return ValueReturn Value
See SPI_execute.Return Value
Return ValueReturn Value
See SPI_execute_plan.
SPI_processed and SPI_tuptable are set as in SPI_execute if successful.Return Value
Return ValueReturn Value
The return value is the same as for SPI_execute.
When options->dest is NULL, SPI_processed and SPI_tuptable are set as in SPI_execute. When options->dest is not NULL, SPI_proces…Return Value
Return ValueReturn Value
The return value is the same as for SPI_execute_plan.
When options->dest is NULL, SPI_processed and SPI_tuptable are set as in SPI_execute_plan. When options->dest is not NULL, …Return Value
Return ValueReturn Value
The return value is the same as for SPI_execute_plan.
SPI_processed and SPI_tuptable are set as in SPI_execute_plan if successful.Return Value
Return ValueReturn Value
The return value is the same as for SPI_execute, with the following additional possible error (negative) results:
SPI_ERROR_ARGUMENT if plan is NULL or invalid, or count is less…Return Value
Return ValueReturn Value
The return value is the same as for SPI_execute.
SPI_processed and SPI_tuptable are set as in SPI_execute if successful.Return Value
More results
Find definitions in the PostgreSQL manuals, reference library, and extension catalogue.
pg17: choose a version ex: extensions only ↑↓ select ↵ open