mirror of
https://github.com/postgres/postgres.git
synced 2025-12-21 05:21:08 +03:00
Basic foreign table support.
Foreign tables are a core component of SQL/MED. This commit does not provide a working SQL/MED infrastructure, because foreign tables cannot yet be queried. Support for foreign table scans will need to be added in a future patch. However, this patch creates the necessary system catalog structure, syntax support, and support for ancillary operations such as COMMENT and SECURITY LABEL. Shigeru Hanada, heavily revised by Robert Haas
This commit is contained in:
@@ -867,12 +867,14 @@ testdb=>
|
||||
|
||||
<listitem>
|
||||
<para>
|
||||
For each relation (table, view, index, or sequence) matching the
|
||||
For each relation (table, view, index, sequence or foreign table)
|
||||
matching the
|
||||
<replaceable class="parameter">pattern</replaceable>, show all
|
||||
columns, their types, the tablespace (if not the default) and any
|
||||
special attributes such as <literal>NOT NULL</literal> or defaults.
|
||||
Associated indexes, constraints, rules, and triggers are
|
||||
also shown.
|
||||
also shown. For foreign tables, the associated foreign
|
||||
server is shown as well.
|
||||
(<quote>Matching the pattern</> is defined in
|
||||
<xref linkend="APP-PSQL-patterns" endterm="APP-PSQL-patterns-title">
|
||||
below.)
|
||||
@@ -882,7 +884,8 @@ testdb=>
|
||||
The command form <literal>\d+</literal> is identical, except that
|
||||
more information is displayed: any comments associated with the
|
||||
columns of the table are shown, as is the presence of OIDs in the
|
||||
table, and the view definition if the relation is a view.
|
||||
table, the view definition if the relation is a view, and the generic
|
||||
options if the relation is a foreign table.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
@@ -895,9 +898,9 @@ testdb=>
|
||||
<para>
|
||||
If <command>\d</command> is used without a
|
||||
<replaceable class="parameter">pattern</replaceable> argument, it is
|
||||
equivalent to <command>\dtvs</command> which will show a list of
|
||||
all visible tables, views, and sequences. This is purely a convenience
|
||||
measure.
|
||||
equivalent to <command>\dtvsE</command> which will show a list of
|
||||
all visible tables, views, sequences and foreign tables.
|
||||
This is purely a convenience measure.
|
||||
</para>
|
||||
</note>
|
||||
</listitem>
|
||||
@@ -1034,6 +1037,20 @@ testdb=>
|
||||
</varlistentry>
|
||||
|
||||
|
||||
<varlistentry>
|
||||
<term><literal>\det[+] [ <link linkend="APP-PSQL-patterns"><replaceable class="parameter">pattern</replaceable></link> ]</literal></term>
|
||||
<listitem>
|
||||
<para>
|
||||
Lists foreign tables (mnemonic: <quote>external tables</quote>).
|
||||
If <replaceable class="parameter">pattern</replaceable> is
|
||||
specified, only entries whose table name or schema name matches
|
||||
the pattern are listed. If the form <literal>\det+</literal>
|
||||
is used, generic options are also displayed.
|
||||
</para>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
||||
|
||||
<varlistentry>
|
||||
<term><literal>\des[+] [ <link linkend="APP-PSQL-patterns"><replaceable class="parameter">pattern</replaceable></link> ]</literal></term>
|
||||
<listitem>
|
||||
@@ -1197,13 +1214,15 @@ testdb=>
|
||||
<term><literal>\ds[S+] [ <link linkend="APP-PSQL-patterns"><replaceable class="parameter">pattern</replaceable></link> ]</literal></term>
|
||||
<term><literal>\dt[S+] [ <link linkend="APP-PSQL-patterns"><replaceable class="parameter">pattern</replaceable></link> ]</literal></term>
|
||||
<term><literal>\dv[S+] [ <link linkend="APP-PSQL-patterns"><replaceable class="parameter">pattern</replaceable></link> ]</literal></term>
|
||||
<term><literal>\dE[S+] [ <link linkend="APP-PSQL-patterns"><replaceable class="parameter">pattern</replaceable></link> ]</literal></term>
|
||||
|
||||
<listitem>
|
||||
<para>
|
||||
In this group of commands, the letters
|
||||
<literal>i</literal>, <literal>s</literal>,
|
||||
<literal>t</literal>, and <literal>v</literal>
|
||||
stand for index, sequence, table, and view, respectively.
|
||||
<literal>t</literal>, <literal>v</literal>, and <literal>E</literal>
|
||||
stand for index, sequence, table, view, and foreign table,
|
||||
respectively.
|
||||
You can specify any or all of
|
||||
these letters, in any order, to obtain a listing of objects
|
||||
of these types. For example, <literal>\dit</> lists indexes
|
||||
|
||||
Reference in New Issue
Block a user