show all; - Mailing list pgsql-patches
From | Marko Kreen |
---|---|
Subject | show all; |
Date | |
Msg-id | 20010601220939.A27062@l-t.ee Whole thread Raw |
Responses |
Re: show all;
(Bruce Momjian <pgman@candle.pha.pa.us>)
Re: show all; (Bruce Momjian <pgman@candle.pha.pa.us>) Re: show all; (Tom Lane <tgl@sss.pgh.pa.us>) Re: show all; (Peter Eisentraut <peter_e@gmx.net>) Re: show all; (Bruce Momjian <pgman@candle.pha.pa.us>) |
List | pgsql-patches |
As SHOW is for humans anyway, I hacked SHOW ALL that shows all current session variables. More info with less typing. I have not looked if the doc changes look sane, because I have not sgml tools on my machine ATM. -- marko Index: doc/src/sgml/ref/show.sgml =================================================================== RCS file: /home/projects/pgsql/cvsroot/pgsql/doc/src/sgml/ref/show.sgml,v retrieving revision 1.11 diff -c -r1.11 show.sgml *** doc/src/sgml/ref/show.sgml 2000/12/25 23:15:26 1.11 --- doc/src/sgml/ref/show.sgml 2001/06/01 19:58:59 *************** *** 16,21 **** --- 16,24 ---- <synopsis> SHOW <replaceable class="PARAMETER">name</replaceable> </synopsis> + <synopsis> + SHOW ALL + </synopsis> <refsect2 id="R2-SQL-SHOW-1"> <title>Inputs</title> *************** *** 29,34 **** --- 32,43 ---- The name of a run-time parameter. See <xref linkend="sql-set" endterm="sql-set-title"> for a list. + </para> + </listitem> + <term>ALL</term> + <listitem> + <para> + Show all current session parameters. </para> </listitem> </varlistentry> Index: src/backend/commands/variable.c =================================================================== RCS file: /home/projects/pgsql/cvsroot/pgsql/src/backend/commands/variable.c,v retrieving revision 1.48 diff -c -r1.48 variable.c *** src/backend/commands/variable.c 2001/05/08 21:06:42 1.48 --- src/backend/commands/variable.c 2001/06/01 19:59:01 *************** *** 748,754 **** show_server_encoding(); else if (strcasecmp(name, "seed") == 0) show_random_seed(); ! else { const char *val = GetConfigOption(name); --- 748,763 ---- show_server_encoding(); else if (strcasecmp(name, "seed") == 0) show_random_seed(); ! else if (strcasecmp(name, "all") == 0) ! { ! show_date(); ! show_timezone(); ! show_DefaultXactIsoLevel(); ! show_XactIsoLevel(); ! show_client_encoding(); ! show_server_encoding(); ! show_random_seed(); ! } else { const char *val = GetConfigOption(name); Index: src/backend/parser/gram.y =================================================================== RCS file: /home/projects/pgsql/cvsroot/pgsql/src/backend/parser/gram.y,v retrieving revision 2.227 diff -c -r2.227 gram.y *** src/backend/parser/gram.y 2001/05/27 09:59:29 2.227 --- src/backend/parser/gram.y 2001/06/01 19:59:14 *************** *** 860,865 **** --- 860,871 ---- n->name = "timezone"; $$ = (Node *) n; } + | SHOW ALL + { + VariableShowStmt *n = makeNode(VariableShowStmt); + n->name = "all"; + $$ = (Node *) n; + } | SHOW TRANSACTION ISOLATION LEVEL { VariableShowStmt *n = makeNode(VariableShowStmt);
pgsql-patches by date: