aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Paquier <michael@paquier.xyz>2023-11-30 14:19:29 +0900
committerMichael Paquier <michael@paquier.xyz>2023-11-30 14:19:29 +0900
commita243569bf65c5664436e8f63d870b7ee9c014dcb (patch)
tree729f18afb6abe5c53fb93454a5e70b696c64db80
parent8d9978a7176a2805a8188605de3c16ffc914dc8a (diff)
downloadpostgresql-a243569bf65c5664436e8f63d870b7ee9c014dcb.tar.gz
postgresql-a243569bf65c5664436e8f63d870b7ee9c014dcb.zip
doc: Mention how to use quotes with GUC names in error messages
Quotes should not be used except if a GUC name is a natural English word. Author: Álvaro Herrera Discussion: https://postgr.es/m/CAHut+Pv-kSN8SkxSdoHano_wPubqcg5789ejhCDZAcLFceBR-w@mail.gmail.com
-rw-r--r--doc/src/sgml/sources.sgml8
1 files changed, 8 insertions, 0 deletions
diff --git a/doc/src/sgml/sources.sgml b/doc/src/sgml/sources.sgml
index 06d995e4b76..5d1d510f8e7 100644
--- a/doc/src/sgml/sources.sgml
+++ b/doc/src/sgml/sources.sgml
@@ -539,6 +539,14 @@ Hint: The addendum, written as a complete sentence.
</para>
<para>
+ In messages containing configuration variable names, do not include quotes
+ when the names are visibly not natural English words, such as when they
+ have underscores, are all-uppercase or have mixed case. Otherwise, quotes
+ must be added. Do include quotes in a message where an arbitrary variable
+ name is to be expanded.
+ </para>
+
+ <para>
There are functions in the backend that will double-quote their own output
as needed (for example, <function>format_type_be()</function>). Do not put
additional quotes around the output of such functions.