|
|
@ -1076,27 +1076,25 @@ ExecForeignTruncate(List *rels, |
|
|
|
bool restart_seqs); |
|
|
|
bool restart_seqs); |
|
|
|
</programlisting> |
|
|
|
</programlisting> |
|
|
|
|
|
|
|
|
|
|
|
Truncate a set of foreign tables specified in <literal>rels</literal>. |
|
|
|
Truncate foreign tables. This function is called when |
|
|
|
This function is called when <xref linkend="sql-truncate"/> is executed |
|
|
|
<xref linkend="sql-truncate"/> is executed on a foreign table. |
|
|
|
on foreign tables. <literal>rels</literal> is the list of |
|
|
|
<literal>rels</literal> is a list of <structname>Relation</structname> |
|
|
|
<structname>Relation</structname> data structure that indicates |
|
|
|
data structures of foreign tables to truncate. |
|
|
|
a foreign table to truncate. |
|
|
|
|
|
|
|
</para> |
|
|
|
</para> |
|
|
|
|
|
|
|
|
|
|
|
<para> |
|
|
|
<para> |
|
|
|
<literal>behavior</literal> defines how foreign tables should |
|
|
|
<literal>behavior</literal> is either <literal>DROP_RESTRICT</literal> |
|
|
|
be truncated, using as possible values <literal>DROP_RESTRICT</literal>, |
|
|
|
or <literal>DROP_CASCADE</literal> indicating that the |
|
|
|
which means that <literal>RESTRICT</literal> option is specified, |
|
|
|
<literal>RESTRICT</literal> or <literal>CASCADE</literal> option was |
|
|
|
and <literal>DROP_CASCADE</literal>, which means that |
|
|
|
requested in the original <command>TRUNCATE</command> command, |
|
|
|
<literal>CASCADE</literal> option is specified, in |
|
|
|
respectively. |
|
|
|
<command>TRUNCATE</command> command. |
|
|
|
|
|
|
|
</para> |
|
|
|
</para> |
|
|
|
|
|
|
|
|
|
|
|
<para> |
|
|
|
<para> |
|
|
|
<literal>restart_seqs</literal> is set to <literal>true</literal> |
|
|
|
If <literal>restart_seqs</literal> is <literal>true</literal>, |
|
|
|
if <literal>RESTART IDENTITY</literal> option is specified in |
|
|
|
the original <command>TRUNCATE</command> command requested the |
|
|
|
<command>TRUNCATE</command> command. It is <literal>false</literal> |
|
|
|
<literal>RESTART IDENTITY</literal> behavior, otherwise the |
|
|
|
if <literal>CONTINUE IDENTITY</literal> option is specified. |
|
|
|
<literal>CONTINUE IDENTITY</literal> behavior was requested. |
|
|
|
</para> |
|
|
|
</para> |
|
|
|
|
|
|
|
|
|
|
|
<para> |
|
|
|
<para> |
|
|
@ -1109,11 +1107,10 @@ ExecForeignTruncate(List *rels, |
|
|
|
</para> |
|
|
|
</para> |
|
|
|
|
|
|
|
|
|
|
|
<para> |
|
|
|
<para> |
|
|
|
<command>TRUNCATE</command> invokes |
|
|
|
<function>ExecForeignTruncate</function> is invoked once per |
|
|
|
<function>ExecForeignTruncate</function> once per foreign server |
|
|
|
foreign server for which foreign tables are to be truncated. |
|
|
|
that foreign tables to truncate belong to. This means that all foreign |
|
|
|
This means that all foreign tables included in <literal>rels</literal> |
|
|
|
tables included in <literal>rels</literal> must belong to the same |
|
|
|
must belong to the same server. |
|
|
|
server. |
|
|
|
|
|
|
|
</para> |
|
|
|
</para> |
|
|
|
|
|
|
|
|
|
|
|
<para> |
|
|
|
<para> |
|
|
|