aboutsummaryrefslogtreecommitdiff
path: root/doc/src
diff options
context:
space:
mode:
authorRobert Haas <rhaas@postgresql.org>2010-07-22 01:22:35 +0000
committerRobert Haas <rhaas@postgresql.org>2010-07-22 01:22:35 +0000
commitce68df468a41d8dbb992184aad490c07d02ca721 (patch)
tree4ec28090880de2036493b915c7fb8c0fdb31ba2a /doc/src
parentb8c6c71d1c513391975fc107a95f104aeeac3117 (diff)
downloadpostgresql-ce68df468a41d8dbb992184aad490c07d02ca721.tar.gz
postgresql-ce68df468a41d8dbb992184aad490c07d02ca721.zip
Add options to force quoting of all identifiers.
I've added a quote_all_identifiers GUC which affects the behavior of the backend, and a --quote-all-identifiers argument to pg_dump and pg_dumpall which sets the GUC and also affects the quoting done internally by those applications. Design by Tom Lane; review by Alex Hunsaker; in response to bug #5488 filed by Hartmut Goebel.
Diffstat (limited to 'doc/src')
-rw-r--r--doc/src/sgml/config.sgml19
-rw-r--r--doc/src/sgml/ref/pg_dump.sgml13
-rw-r--r--doc/src/sgml/ref/pg_dumpall.sgml13
3 files changed, 42 insertions, 3 deletions
diff --git a/doc/src/sgml/config.sgml b/doc/src/sgml/config.sgml
index c343bee9d09..0f20e75fbce 100644
--- a/doc/src/sgml/config.sgml
+++ b/doc/src/sgml/config.sgml
@@ -1,4 +1,4 @@
-<!-- $PostgreSQL: pgsql/doc/src/sgml/config.sgml,v 1.298 2010/07/20 00:47:52 rhaas Exp $ -->
+<!-- $PostgreSQL: pgsql/doc/src/sgml/config.sgml,v 1.299 2010/07/22 01:22:32 rhaas Exp $ -->
<chapter Id="runtime-config">
<title>Server Configuration</title>
@@ -5209,6 +5209,23 @@ dynamic_library_path = 'C:\tools\postgresql;H:\my_project\lib;$libdir'
</listitem>
</varlistentry>
+ <varlistentry id="guc-quote-all-identifiers" xreflabel="quote-all-identifiers">
+ <term><varname>quote_all_identifiers</varname> (<type>boolean</type>)</term>
+ <indexterm>
+ <primary><varname>quote_all_identifiers</> configuration parameter</primary>
+ </indexterm>
+ <listitem>
+ <para>
+ When the database generates SQL, force all identifiers to be quoted,
+ even if they are not (currently) keywords. This will affect the
+ output of <command>EXPLAIN</> as well as the results of functions
+ like <function>pg_get_viewdef</>. See also the
+ <option>--quote-all-identifiers</option> to
+ <xref linkend="app-pgdump"> and <xref linkend="app-pg-dumpall">.
+ </para>
+ </listitem>
+ </varlistentry>
+
<varlistentry id="guc-sql-inheritance" xreflabel="sql_inheritance">
<term><varname>sql_inheritance</varname> (<type>boolean</type>)</term>
<indexterm>
diff --git a/doc/src/sgml/ref/pg_dump.sgml b/doc/src/sgml/ref/pg_dump.sgml
index 0f254d45ad7..f0498df50ce 100644
--- a/doc/src/sgml/ref/pg_dump.sgml
+++ b/doc/src/sgml/ref/pg_dump.sgml
@@ -1,5 +1,5 @@
<!--
-$PostgreSQL: pgsql/doc/src/sgml/ref/pg_dump.sgml,v 1.117 2010/02/23 17:28:09 tgl Exp $
+$PostgreSQL: pgsql/doc/src/sgml/ref/pg_dump.sgml,v 1.118 2010/07/22 01:22:33 rhaas Exp $
PostgreSQL documentation
-->
@@ -661,6 +661,17 @@ PostgreSQL documentation
</varlistentry>
<varlistentry>
+ <term><option>--quote-all-identifiers</></term>
+ <listitem>
+ <para>
+ Force quoting of all identifiers. This may be useful when dumping a
+ database for migration to a future version that may have introduced
+ additional keywords.
+ </para>
+ </listitem>
+ </varlistentry>
+
+ <varlistentry>
<term><option>-?</></term>
<term><option>--help</></term>
<listitem>
diff --git a/doc/src/sgml/ref/pg_dumpall.sgml b/doc/src/sgml/ref/pg_dumpall.sgml
index 95a37512ee1..75097308851 100644
--- a/doc/src/sgml/ref/pg_dumpall.sgml
+++ b/doc/src/sgml/ref/pg_dumpall.sgml
@@ -1,5 +1,5 @@
<!--
-$PostgreSQL: pgsql/doc/src/sgml/ref/pg_dumpall.sgml,v 1.82 2010/04/03 07:23:01 petere Exp $
+$PostgreSQL: pgsql/doc/src/sgml/ref/pg_dumpall.sgml,v 1.83 2010/07/22 01:22:33 rhaas Exp $
PostgreSQL documentation
-->
@@ -357,6 +357,17 @@ PostgreSQL documentation
</varlistentry>
<varlistentry>
+ <term><option>--quote-all-identifiers</></term>
+ <listitem>
+ <para>
+ Force quoting of all identifiers. This may be useful when dumping a
+ database for migration to a future version that may have introduced
+ additional keywords.
+ </para>
+ </listitem>
+ </varlistentry>
+
+ <varlistentry>
<term><option>-?</></term>
<term><option>--help</></term>
<listitem>