Search PostgreSQL documentation
PG 18 · Browse by category, or enter a name or keyword
Popular entries9783
NotesNotes
psql works best with servers of the same or an older major version. Backslash commands are particularly likely to fail if the server is of a newer version than psql itself. However, ba…Notes
NotesF.5.2. Notes
Server crashes may leave temporary files with the prefix archtemp in the archive directory. It is recommended to delete such files before restarting the server after a crash. It…Notes
NotesNotes
As of PostgreSQL 9.0, the attribute numbers in primary_key_attnums are interpreted as logical column numbers, corresponding to the column's position in SELECT * FROM relname. Previous …Notes
NotesNotes
As of PostgreSQL 9.0, the attribute numbers in primary_key_attnums are interpreted as logical column numbers, corresponding to the column's position in SELECT * FROM relname. Previous …Notes
NotesNotes
As of PostgreSQL 9.0, the attribute numbers in primary_key_attnums are interpreted as logical column numbers, corresponding to the column's position in SELECT * FROM relname. Previous …Notes
NotesNotes
If dblink_open started an explicit transaction block, and this is the last remaining open cursor in this connection, dblink_close will issue the matching COMMIT.Notes
NotesNotes
If untrusted users have access to a database that has not adopted a secure schema usage pattern, begin each session by removing publicly-writable schemas from search_path. One could, f…Notes
NotesNotes
When asynchronous queries are initiated by dblink_send_query, the error message associated with the connection might not get updated until the server's response message is consumed. Th…Notes
NotesNotes
On a mismatch between the number of return columns specified in the FROM clause, and the actual number of columns returned by the remote cursor, an error will be thrown. In this event,…Notes
NotesNotes
A convenient way to use dblink with predetermined queries is to create a view. This allows the column type information to be buried in the view, instead of having to spell it out in ev…Notes
NotesNotes
This function must be called if dblink_send_query returned 1. It must be called once for each query sent, and one additional time to obtain an empty set result, before the connection c…Notes
NotesNotes
Since a cursor can only persist within a transaction, dblink_open starts an explicit transaction block (BEGIN) on the remote side, if the remote side was not already within a transacti…Notes
NotesF.10.5. Notes
For examples of usage, see the regression test sql/cube.sql.
To make it harder for people to break things, there is a limit of 100 on the number of dimensions of cubes. This is…Notes
NotesNotes
This association is valid only if the declaration is physically placed on top of a dynamic statement.Notes
NotesNotes
In typical usage, the string is a host variable reference to a string containing a dynamically-constructed SQL statement. The case of a literal string is not very useful; you might as …Notes
NotesNotes
In typical usage, the string is a host variable reference to a string containing a dynamically-constructed SQL statement. The case of a literal string is not very useful; you might as …Notes
NotesNotes
oid2name requires a running database server with non-corrupt system catalogs. It is therefore of only limited use for recovering from catastrophic database corruption situations.Notes
NotesNotes
pg_archivecleanup is designed to work with PostgreSQL 8.0 and later when used as a standalone utility, or with PostgreSQL 9.0 and later when used as an archive cleanup command.
pg_arch…Notes
NotesNotesNotes
NotesF.26.8. NotesNotes
NotesNotes
pg_upgrade creates various working files, such as schema dumps, stored within pg_upgrade_output.d in the directory of the new cluster. Each run creates a new subdirectory named with a …Notes
NotesNotes
Can give wrong results when the server is running.
Only the specified timeline is displayed (or the default, if none is specified). Records in other timelines are ignored.
pg_waldump c…Notes
NotesF.39.5. Notes
For examples of usage, see the regression test sql/seg.sql.
The mechanism that converts (+-) to regular ranges isn't completely accurate in determining the number of significan…Notes
NotesNotes
Fetching backward may fail if the cursor's plan was not created with the CURSOR_OPT_SCROLL option.Notes
NotesNotes
Beware that this function can return a Portal object that does not have cursor-like properties; for example it might not return tuples. If you simply pass the Portal pointer to other S…Notes
NotesNotes
Moving backward may fail if the cursor's plan was not created with the CURSOR_OPT_SCROLL option.Notes
NotesNotes
All SPI query-execution functions set both SPI_processed and SPI_tuptable (just the pointer, not the contents of the structure). Save these two global variables into local C function v…Notes
NotesNotes
The passed-in statement is relocated to permanent storage by means of pointer adjustment (no data copying is required). If you later wish to delete it, use SPI_freeplan on it.Notes
NotesNotes
Useful bits to set in cursorOptions include CURSOR_OPT_SCROLL, CURSOR_OPT_NO_SCROLL, CURSOR_OPT_FAST_PLAN, CURSOR_OPT_GENERIC_PLAN, and CURSOR_OPT_CUSTOM_PLAN. Note in particular that …Notes
NotesNotes
If no parameters are defined, a generic plan will be created at the first use of SPI_execute_plan, and used for all subsequent executions as well. If there are parameters, the first fe…Notes
NotesNotes
The originally passed-in statement is not freed, so you might wish to do SPI_freeplan on it to avoid leaking memory until SPI_finish.
In most cases, SPI_keepplan is preferred to this f…Notes
NotesNotes
See the SQL FETCH command for details of the interpretation of the direction and count parameters.
Direction values other than FETCH_FORWARD may fail if the cursor's plan was not creat…Notes
NotesNotes
See the SQL FETCH command for details of the interpretation of the direction and count parameters.
Direction values other than FETCH_FORWARD may fail if the cursor's plan was not creat…Notes
NotesNotes
Use COMMIT to successfully terminate a transaction.
Issuing ABORT outside of a transaction block emits a warning and otherwise has no effect.Notes
NotesNotes
The recommended syntax for referencing an ordered-set aggregate is to write ORDER BY between the direct and aggregated argument specifications, in the same style as in CREATE AGGREGATE…Notes
NotesNotes
When a collation object is created, the provider-specific version of the collation is recorded in the system catalog. When the collation is used, the current version is checked against…Notes
NotesNotes
It is also possible to tie a session default to a specific role rather than to a database; see ALTER ROLE. Role-specific settings override database-specific ones if there is a conflict…Notes
NotesNotes
Use psql's \ddp command to obtain information about existing assignments of default privileges. The meaning of the privilege display is the same as explained for \dp in Section 5.8.
If…Notes
NotesNotes
Although ALTER DOMAIN ADD CONSTRAINT attempts to verify that existing stored data satisfies the new constraint, this check is not bulletproof, because the command cannot “see” table ro…Notes
NotesNotes
The key word COLUMN is noise and can be omitted.
Consistency with the foreign server is not checked when a column is added or removed with ADD COLUMN or DROP COLUMN, a NOT NULL or CHEC…Notes
More results
Find definitions in the PostgreSQL manuals, reference library, and extension catalogue.
pg17: choose a version ex: extensions only ↑↓ select ↵ open