mirror of
https://github.com/postgres/postgres.git
synced 2025-05-08 07:21:33 +03:00
Allow EXPLAIN on CREATE TABLE AS.
This commit is contained in:
parent
e5da8e15ba
commit
5163b94e6f
@ -1,5 +1,5 @@
|
|||||||
<!--
|
<!--
|
||||||
$PostgreSQL: pgsql/doc/src/sgml/ref/explain.sgml,v 1.42 2008/04/18 01:42:17 tgl Exp $
|
$PostgreSQL: pgsql/doc/src/sgml/ref/explain.sgml,v 1.43 2008/10/27 08:47:13 petere Exp $
|
||||||
PostgreSQL documentation
|
PostgreSQL documentation
|
||||||
-->
|
-->
|
||||||
|
|
||||||
@ -78,7 +78,8 @@ EXPLAIN [ ANALYZE ] [ VERBOSE ] <replaceable class="parameter">statement</replac
|
|||||||
statement will happen as usual. If you wish to use
|
statement will happen as usual. If you wish to use
|
||||||
<command>EXPLAIN ANALYZE</command> on an
|
<command>EXPLAIN ANALYZE</command> on an
|
||||||
<command>INSERT</command>, <command>UPDATE</command>,
|
<command>INSERT</command>, <command>UPDATE</command>,
|
||||||
<command>DELETE</command>, or <command>EXECUTE</command> statement
|
<command>DELETE</command>, <command>CREATE TABLE AS</command>,
|
||||||
|
or <command>EXECUTE</command> statement
|
||||||
without letting the command affect your data, use this approach:
|
without letting the command affect your data, use this approach:
|
||||||
<programlisting>
|
<programlisting>
|
||||||
BEGIN;
|
BEGIN;
|
||||||
@ -116,8 +117,9 @@ ROLLBACK;
|
|||||||
<listitem>
|
<listitem>
|
||||||
<para>
|
<para>
|
||||||
Any <command>SELECT</>, <command>INSERT</>, <command>UPDATE</>,
|
Any <command>SELECT</>, <command>INSERT</>, <command>UPDATE</>,
|
||||||
<command>DELETE</>, <command>VALUES</>, <command>EXECUTE</>, or
|
<command>DELETE</>, <command>VALUES</>, <command>EXECUTE</>,
|
||||||
<command>DECLARE</> statement, whose execution plan you wish to see.
|
<command>DECLARE</>, or <command>CREATE TABLE AS</command>
|
||||||
|
statement, whose execution plan you wish to see.
|
||||||
</para>
|
</para>
|
||||||
</listitem>
|
</listitem>
|
||||||
</varlistentry>
|
</varlistentry>
|
||||||
|
@ -11,7 +11,7 @@
|
|||||||
*
|
*
|
||||||
*
|
*
|
||||||
* IDENTIFICATION
|
* IDENTIFICATION
|
||||||
* $PostgreSQL: pgsql/src/backend/parser/gram.y,v 2.628 2008/10/22 11:00:34 petere Exp $
|
* $PostgreSQL: pgsql/src/backend/parser/gram.y,v 2.629 2008/10/27 08:47:14 petere Exp $
|
||||||
*
|
*
|
||||||
* HISTORY
|
* HISTORY
|
||||||
* AUTHOR DATE MAJOR EVENT
|
* AUTHOR DATE MAJOR EVENT
|
||||||
@ -5898,6 +5898,7 @@ ExplainableStmt:
|
|||||||
| UpdateStmt
|
| UpdateStmt
|
||||||
| DeleteStmt
|
| DeleteStmt
|
||||||
| DeclareCursorStmt
|
| DeclareCursorStmt
|
||||||
|
| CreateAsStmt
|
||||||
| ExecuteStmt /* by default all are $$=$1 */
|
| ExecuteStmt /* by default all are $$=$1 */
|
||||||
;
|
;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user