1DROP FOREIGN TABLE(7)    PostgreSQL 10.7 Documentation   DROP FOREIGN TABLE(7)
2
3
4

NAME

6       DROP_FOREIGN_TABLE - remove a foreign table
7

SYNOPSIS

9       DROP FOREIGN TABLE [ IF EXISTS ] name [, ...] [ CASCADE | RESTRICT ]
10

DESCRIPTION

12       DROP FOREIGN TABLE removes a foreign table. Only the owner of a foreign
13       table can remove it.
14

PARAMETERS

16       IF EXISTS
17           Do not throw an error if the foreign table does not exist. A notice
18           is issued in this case.
19
20       name
21           The name (optionally schema-qualified) of the foreign table to
22           drop.
23
24       CASCADE
25           Automatically drop objects that depend on the foreign table (such
26           as views), and in turn all objects that depend on those objects
27           (see Section 5.13).
28
29       RESTRICT
30           Refuse to drop the foreign table if any objects depend on it. This
31           is the default.
32

EXAMPLES

34       To destroy two foreign tables, films and distributors:
35
36           DROP FOREIGN TABLE films, distributors;
37

COMPATIBILITY

39       This command conforms to the ISO/IEC 9075-9 (SQL/MED), except that the
40       standard only allows one foreign table to be dropped per command, and
41       apart from the IF EXISTS option, which is a PostgreSQL extension.
42

SEE ALSO

44       ALTER FOREIGN TABLE (ALTER_FOREIGN_TABLE(7)), CREATE FOREIGN TABLE
45       (CREATE_FOREIGN_TABLE(7))
46
47
48
49PostgreSQL 10.7                      2019                DROP FOREIGN TABLE(7)
Impressum