postgresql/doc/src/sgml/ref
Tom Lane 92bf7e2d02 Provide the OR REPLACE option for CREATE TRIGGER.
This is mostly straightforward.  However, we disallow replacing
constraint triggers or changing the is-constraint property; perhaps
that can be added later, but the complexity versus benefit tradeoff
doesn't look very good.

Also, no special thought is taken here for whether replacing an
existing trigger should result in changes to queued-but-not-fired
trigger actions.  We just document that if you're surprised by the
results, too bad, don't do that.  (Note that any such pending trigger
activity would have to be within the current session.)

Takamichi Osumi, reviewed at various times by Surafel Temesgen,
Peter Smith, and myself

Discussion: https://postgr.es/m/0DDF369B45A1B44B8A687ED43F06557C010BC362@G01JPEXMBYT03
2020-11-14 17:05:34 -05:00
..
abort.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
allfiles.sgml Rename pg_validatebackup to pg_verifybackup. 2020-04-12 11:26:05 -04:00
alter_aggregate.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
alter_collation.sgml Remove pg_collation.collversion. 2020-11-03 00:44:59 +13:00
alter_conversion.sgml Allow CURRENT_ROLE where CURRENT_USER is accepted 2020-09-17 11:40:08 +02:00
alter_database.sgml Allow CURRENT_ROLE where CURRENT_USER is accepted 2020-09-17 11:40:08 +02:00
alter_default_privileges.sgml
alter_domain.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
alter_event_trigger.sgml Allow CURRENT_ROLE where CURRENT_USER is accepted 2020-09-17 11:40:08 +02:00
alter_extension.sgml Support for OUT parameters in procedures 2020-10-05 09:21:43 +02:00
alter_foreign_data_wrapper.sgml Allow CURRENT_ROLE where CURRENT_USER is accepted 2020-09-17 11:40:08 +02:00
alter_foreign_table.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
alter_function.sgml Allow CURRENT_ROLE where CURRENT_USER is accepted 2020-09-17 11:40:08 +02:00
alter_group.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
alter_index.sgml Track collation versions for indexes. 2020-11-03 01:19:50 +13:00
alter_language.sgml Allow CURRENT_ROLE where CURRENT_USER is accepted 2020-09-17 11:40:08 +02:00
alter_large_object.sgml Allow CURRENT_ROLE where CURRENT_USER is accepted 2020-09-17 11:40:08 +02:00
alter_materialized_view.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
alter_opclass.sgml Allow CURRENT_ROLE where CURRENT_USER is accepted 2020-09-17 11:40:08 +02:00
alter_operator.sgml Remove support for postfix (right-unary) operators. 2020-09-17 19:38:05 -04:00
alter_opfamily.sgml Remove support for postfix (right-unary) operators. 2020-09-17 19:38:05 -04:00
alter_policy.sgml Allow CURRENT_ROLE where CURRENT_USER is accepted 2020-09-17 11:40:08 +02:00
alter_procedure.sgml Support for OUT parameters in procedures 2020-10-05 09:21:43 +02:00
alter_publication.sgml Allow CURRENT_ROLE where CURRENT_USER is accepted 2020-09-17 11:40:08 +02:00
alter_role.sgml Allow users with BYPASSRLS to alter their own passwords. 2020-11-03 15:41:32 -05:00
alter_routine.sgml Allow CURRENT_ROLE where CURRENT_USER is accepted 2020-09-17 11:40:08 +02:00
alter_rule.sgml
alter_schema.sgml Allow CURRENT_ROLE where CURRENT_USER is accepted 2020-09-17 11:40:08 +02:00
alter_sequence.sgml Allow CURRENT_ROLE where CURRENT_USER is accepted 2020-09-17 11:40:08 +02:00
alter_server.sgml Allow CURRENT_ROLE where CURRENT_USER is accepted 2020-09-17 11:40:08 +02:00
alter_statistics.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
alter_subscription.sgml Allow CURRENT_ROLE where CURRENT_USER is accepted 2020-09-17 11:40:08 +02:00
alter_system.sgml
alter_table.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
alter_tablespace.sgml Allow CURRENT_ROLE where CURRENT_USER is accepted 2020-09-17 11:40:08 +02:00
alter_trigger.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
alter_tsconfig.sgml Allow CURRENT_ROLE where CURRENT_USER is accepted 2020-09-17 11:40:08 +02:00
alter_tsdictionary.sgml Allow CURRENT_ROLE where CURRENT_USER is accepted 2020-09-17 11:40:08 +02:00
alter_tsparser.sgml
alter_tstemplate.sgml
alter_type.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
alter_user.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
alter_user_mapping.sgml Allow CURRENT_ROLE where CURRENT_USER is accepted 2020-09-17 11:40:08 +02:00
alter_view.sgml Allow CURRENT_ROLE where CURRENT_USER is accepted 2020-09-17 11:40:08 +02:00
analyze.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
begin.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
call.sgml
checkpoint.sgml doc: make ref/*.sgml file header comment layout consistent 2020-05-15 08:52:24 -04:00
close.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
cluster.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
clusterdb.sgml Fix connection string handling in src/bin/scripts/ programs. 2020-10-19 19:03:46 -04:00
comment.sgml Support for OUT parameters in procedures 2020-10-05 09:21:43 +02:00
commit.sgml
commit_prepared.sgml
copy.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
create_access_method.sgml
create_aggregate.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
create_cast.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
create_collation.sgml Remove pg_collation.collversion. 2020-11-03 00:44:59 +13:00
create_conversion.sgml doc: make ref/*.sgml file header comment layout consistent 2020-05-15 08:52:24 -04:00
create_database.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
create_domain.sgml
create_event_trigger.sgml doc: add commas after 'i.e.' and 'e.g.' 2020-08-31 18:33:37 -04:00
create_extension.sgml Make contrib modules' installation scripts more secure. 2020-08-10 10:44:42 -04:00
create_foreign_data_wrapper.sgml
create_foreign_table.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
create_function.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
create_group.sgml Doc: sync CREATE GROUP syntax synopsis with CREATE ROLE. 2020-04-10 10:44:09 -04:00
create_index.sgml docs: mention that expression indexes need analyze 2020-11-12 15:00:44 -05:00
create_language.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
create_materialized_view.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
create_opclass.sgml Remove support for postfix (right-unary) operators. 2020-09-17 19:38:05 -04:00
create_operator.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
create_opfamily.sgml
create_policy.sgml Allow CURRENT_ROLE where CURRENT_USER is accepted 2020-09-17 11:40:08 +02:00
create_procedure.sgml Support for OUT parameters in procedures 2020-10-05 09:21:43 +02:00
create_publication.sgml doc: Fix man page whitespace issues 2020-06-07 14:54:28 +02:00
create_role.sgml Allow users with BYPASSRLS to alter their own passwords. 2020-11-03 15:41:32 -05:00
create_rule.sgml
create_schema.sgml Allow CURRENT_ROLE where CURRENT_USER is accepted 2020-09-17 11:40:08 +02:00
create_sequence.sgml
create_server.sgml
create_statistics.sgml doc: add commas after 'i.e.' and 'e.g.' 2020-08-31 18:33:37 -04:00
create_subscription.sgml doc: Fix some grammar and inconsistencies 2020-09-10 15:50:19 +09:00
create_table.sgml Clarify temporary table name shadowing in CREATE TABLE docs 2020-11-02 15:00:24 +01:00
create_table_as.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
create_tablespace.sgml Allow CURRENT_ROLE where CURRENT_USER is accepted 2020-09-17 11:40:08 +02:00
create_transform.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
create_trigger.sgml Provide the OR REPLACE option for CREATE TRIGGER. 2020-11-14 17:05:34 -05:00
create_tsconfig.sgml
create_tsdictionary.sgml
create_tsparser.sgml
create_tstemplate.sgml
create_type.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
create_user.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
create_user_mapping.sgml Allow CURRENT_ROLE where CURRENT_USER is accepted 2020-09-17 11:40:08 +02:00
create_view.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
createdb.sgml Fix connection string handling in src/bin/scripts/ programs. 2020-10-19 19:03:46 -04:00
createuser.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
deallocate.sgml
declare.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
delete.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
discard.sgml
do.sgml
drop_access_method.sgml
drop_aggregate.sgml
drop_cast.sgml doc: make ref/*.sgml file header comment layout consistent 2020-05-15 08:52:24 -04:00
drop_collation.sgml doc: make ref/*.sgml file header comment layout consistent 2020-05-15 08:52:24 -04:00
drop_conversion.sgml doc: make ref/*.sgml file header comment layout consistent 2020-05-15 08:52:24 -04:00
drop_database.sgml doc: Trim trailing whitespace 2020-06-07 13:24:40 +02:00
drop_domain.sgml
drop_event_trigger.sgml
drop_extension.sgml
drop_foreign_data_wrapper.sgml
drop_foreign_table.sgml doc: make ref/*.sgml file header comment layout consistent 2020-05-15 08:52:24 -04:00
drop_function.sgml doc: Fix man page whitespace issues 2020-06-07 14:54:28 +02:00
drop_group.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
drop_index.sgml Raise error on concurrent drop of partitioned index 2020-09-01 13:40:43 -04:00
drop_language.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
drop_materialized_view.sgml
drop_opclass.sgml
drop_operator.sgml Remove support for postfix (right-unary) operators. 2020-09-17 19:38:05 -04:00
drop_opfamily.sgml
drop_owned.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
drop_policy.sgml
drop_procedure.sgml Support for OUT parameters in procedures 2020-10-05 09:21:43 +02:00
drop_publication.sgml
drop_role.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
drop_routine.sgml doc: Fix man page whitespace issues 2020-06-07 14:54:28 +02:00
drop_rule.sgml
drop_schema.sgml
drop_sequence.sgml
drop_server.sgml
drop_statistics.sgml
drop_subscription.sgml
drop_table.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
drop_tablespace.sgml
drop_transform.sgml doc: make ref/*.sgml file header comment layout consistent 2020-05-15 08:52:24 -04:00
drop_trigger.sgml
drop_tsconfig.sgml
drop_tsdictionary.sgml
drop_tsparser.sgml
drop_tstemplate.sgml
drop_type.sgml
drop_user.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
drop_user_mapping.sgml Allow CURRENT_ROLE where CURRENT_USER is accepted 2020-09-17 11:40:08 +02:00
drop_view.sgml
dropdb.sgml Fix connection string handling in src/bin/scripts/ programs. 2020-10-19 19:03:46 -04:00
dropuser.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
ecpg-ref.sgml Fix our getopt_long's behavior for a command line argument of just "-". 2020-03-23 11:58:00 -04:00
end.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
execute.sgml Doc: fix "Unresolved ID reference" warnings, clean up man page cross-refs. 2020-05-11 14:15:55 -04:00
explain.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
fetch.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
grant.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
import_foreign_schema.sgml
initdb.sgml doc: add commas after 'i.e.' and 'e.g.' 2020-08-31 18:33:37 -04:00
insert.sgml Doc: fix "Unresolved ID reference" warnings, clean up man page cross-refs. 2020-05-11 14:15:55 -04:00
listen.sgml
load.sgml doc: make ref/*.sgml file header comment layout consistent 2020-05-15 08:52:24 -04:00
lock.sgml Revert "Accept relations of any kind in LOCK TABLE". 2020-11-06 16:17:56 -05:00
move.sgml
notify.sgml
pg_basebackup.sgml doc: fix spelling "connction" to "connection" 2020-11-10 19:18:35 -05:00
pg_checksums.sgml doc: Tweak sentence for pg_checksums when enabling checksums 2020-09-07 14:34:59 +09:00
pg_config-ref.sgml Add missing <application> tags in application doc <refentrytitle>s 2020-07-10 16:51:29 +02:00
pg_controldata.sgml
pg_ctl-ref.sgml Fix postmaster's behavior during smart shutdown. 2020-08-14 13:26:57 -04:00
pg_dump.sgml doc: Remove reference to pre-8.2 pg_dump behaviour 2020-10-23 11:49:59 +03:00
pg_dumpall.sgml doc: fix spelling "connction" to "connection" 2020-11-10 19:18:35 -05:00
pg_isready.sgml doc: libpq connection options can override command-line flags 2020-10-02 22:19:31 -04:00
pg_receivewal.sgml doc: fix spelling "connction" to "connection" 2020-11-10 19:18:35 -05:00
pg_recvlogical.sgml doc: libpq connection options can override command-line flags 2020-10-02 22:19:31 -04:00
pg_resetwal.sgml
pg_restore.sgml doc: libpq connection options can override command-line flags 2020-10-02 22:19:31 -04:00
pg_rewind.sgml Allow pg_rewind to use a standby server as the source system. 2020-11-12 14:52:24 +02:00
pg_verifybackup.sgml doc: Fix some grammar and inconsistencies 2020-09-10 15:50:19 +09:00
pg_waldump.sgml pg_waldump: Add a --quiet option. 2020-04-02 20:25:04 -04:00
pgarchivecleanup.sgml doc: make ref/*.sgml file header comment layout consistent 2020-05-15 08:52:24 -04:00
pgbench.sgml Copy editing: fix a bunch of misspellings and poor wording. 2020-09-21 12:43:42 -04:00
pgtestfsync.sgml doc: make ref/*.sgml file header comment layout consistent 2020-05-15 08:52:24 -04:00
pgtesttiming.sgml doc: make ref/*.sgml file header comment layout consistent 2020-05-15 08:52:24 -04:00
pgupgrade.sgml Track collation versions for indexes. 2020-11-03 01:19:50 +13:00
postgres-ref.sgml Remove -o option to postmaster 2020-11-10 13:15:01 +01:00
postmaster.sgml
prepare.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
prepare_transaction.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
psql-ref.sgml Allow psql to re-use connection parameters after a connection loss. 2020-10-23 17:07:15 -04:00
reassign_owned.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
refresh_materialized_view.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
reindex.sgml Track collation versions for indexes. 2020-11-03 01:19:50 +13:00
reindexdb.sgml Fix connection string handling in src/bin/scripts/ programs. 2020-10-19 19:03:46 -04:00
release_savepoint.sgml
reset.sgml
revoke.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
rollback.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
rollback_prepared.sgml
rollback_to.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
savepoint.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
security_label.sgml Support for OUT parameters in procedures 2020-10-05 09:21:43 +02:00
select.sgml Misc documentation fixes. 2020-10-19 19:28:54 +03:00
select_into.sgml Misc documentation fixes. 2020-10-19 19:28:54 +03:00
set.sgml
set_constraints.sgml doc: make ref/*.sgml file header comment layout consistent 2020-05-15 08:52:24 -04:00
set_role.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
set_session_auth.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
set_transaction.sgml doc: make ref/*.sgml file header comment layout consistent 2020-05-15 08:52:24 -04:00
show.sgml
start_transaction.sgml Improve <xref> vs. <command> formatting in the documentation 2020-10-03 16:40:02 +02:00
truncate.sgml Fix TRUNCATE doc: ALTER SEQUENCE RESTART is now transactional. 2020-10-19 19:02:25 +03:00
unlisten.sgml
update.sgml Doc: fix "Unresolved ID reference" warnings, clean up man page cross-refs. 2020-05-11 14:15:55 -04:00
vacuum.sgml Change the docs for PARALLEL option of Vacuum. 2020-10-19 09:13:17 +05:30
vacuumdb.sgml Fix connection string handling in src/bin/scripts/ programs. 2020-10-19 19:03:46 -04:00
values.sgml Doc: fix "Unresolved ID reference" warnings, clean up man page cross-refs. 2020-05-11 14:15:55 -04:00