ALTER TRIGGER

NameALTER TRIGGER -- change the definition of a trigger Synopsis ALTER TRIGGER name ON table_name RENAME TO new_name ALTER TRIGGER name ON table_name DEPENDS ON EXTENSION extension_name Description ALTER TRIGGER changes properties of an existing trigger. The RENAME clause changes the name of the given trigger without otherwise changing the trigger definition. The DEPENDS ON EXTENSION clause marks the trigger as dependent on an extension, such that if the extension is dropped, the trig

DROP FUNCTION

NameDROP FUNCTION -- remove a function Synopsis DROP FUNCTION [ IF EXISTS ] name ( [ [ argmode ] [ argname ] argtype [, ...] ] ) [ CASCADE | RESTRICT ] Description DROP FUNCTION removes the definition of an existing function. To execute this command the user must be the owner of the function. The argument types to the function must be specified, since several different functions can exist with the same name and different argument lists. Parameters IF EXISTS Do not throw an er

ALTER DEFAULT PRIVILEGES

NameALTER DEFAULT PRIVILEGES -- define default access privileges Synopsis ALTER DEFAULT PRIVILEGES [ FOR { ROLE | USER } target_role [, ...] ] [ IN SCHEMA schema_name [, ...] ] abbreviated_grant_or_revoke where abbreviated_grant_or_revoke is one of: GRANT { { SELECT | INSERT | UPDATE | DELETE | TRUNCATE | REFERENCES | TRIGGER } [, ...] | ALL [ PRIVILEGES ] } ON TABLES TO { [ GROUP ] role_name | PUBLIC } [, ...] [ WITH GRANT OPTION ] GRANT { { USAGE | SELECT | UP

Bit String Types

Bit strings are strings of 1's and 0's. They can be used to store or visualize bit masks. There are two SQL bit types: bit(n) and bit varying(n), where n is a positive integer. bit type data must match the length n exactly; it is an error to attempt to store shorter or longer bit strings. bit varying data is of variable length up to the maximum length n; longer strings will be rejected. Writing bit without a length is equivalent to bit(1), while bit varying without a length specification means

Catalogs: pg_operator

The catalog pg_operator stores information about operators. See CREATE OPERATOR and Section 36.12 for more information. Table 50-34. pg_operator Columns Name Type References Description oid oid Row identifier (hidden attribute; must be explicitly selected) oprname name Name of the operator oprnamespace oid pg_namespace.oid The OID of the namespace that contains this operator oprowner oid pg_authid.oid Owner of the operator oprkind char b = infix ("both"), l = prefix ("left"), r = postf

Catalogs: pg_auth_members

The catalog pg_auth_members shows the membership relations between roles. Any non-circular set of relationships is allowed. Because user identities are cluster-wide, pg_auth_members is shared across all databases of a cluster: there is only one copy of pg_auth_members per cluster, not one per database. Table 50-9. pg_auth_members Columns Name Type References Description roleid oid pg_authid.oid ID of a role that has a member member oid pg_authid.oid ID of a role that is a member of roleid gr

pg_upgrade

Namepg_upgrade -- upgrade a PostgreSQL server instance Synopsis pg_upgrade -b oldbindir -B newbindir -d olddatadir -D newdatadir [option...] Description pg_upgrade (formerly called pg_migrator) allows data stored in PostgreSQL data files to be upgraded to a later PostgreSQL major version without the data dump/reload typically required for major version upgrades, e.g. from 8.4.7 to the current major release of PostgreSQL. It is not required for minor version upgrades, e.g. from 9.0.1 to

Internals//GiST Indexes: Implementation

61.4.1. GiST buffering build Building large GiST indexes by simply inserting all the tuples tends to be slow, because if the index tuples are scattered across the index and the index is large enough to not fit in cache, the insertions need to perform a lot of random I/O. Beginning in version 9.2, PostgreSQL supports a more efficient method to build GiST indexes based on buffering, which can dramatically reduce the number of random I/Os needed for non-ordered data sets. For well-ordered data se

Date/Time Input Interpretation

The date/time type inputs are all decoded using the following procedure. Break the input string into tokens and categorize each token as a string, time, time zone, or number. If the numeric token contains a colon (:), this is a time string. Include all subsequent digits and colons. If the numeric token contains a dash (-), slash (/), or two or more dots (.), this is a date string which might have a text month. If a date token has already been seen, it is instead interpreted as a time zone

Catalogs: pg_tablespace

The catalog pg_tablespace stores information about the available tablespaces. Tables can be placed in particular tablespaces to aid administration of disk layout. Unlike most system catalogs, pg_tablespace is shared across all databases of a cluster: there is only one copy of pg_tablespace per cluster, not one per database. Table 50-47. pg_tablespace Columns Name Type References Description oid oid Row identifier (hidden attribute; must be explicitly selected) spcname name Tablespace name