aboutsummaryrefslogtreecommitdiff
path: root/doc/src
diff options
context:
space:
mode:
authorBruce Momjian <bruce@momjian.us>2006-02-12 02:54:30 +0000
committerBruce Momjian <bruce@momjian.us>2006-02-12 02:54:30 +0000
commit07bae9c099f08e9c8af4212f8c636ab6c96ed2dc (patch)
tree8c2f483f06fdfba8f8338805e1fcb26424881ab4 /doc/src
parentd52a57fc300312c5a165e296a1b12a0c4fd668bd (diff)
downloadpostgresql-07bae9c099f08e9c8af4212f8c636ab6c96ed2dc.tar.gz
postgresql-07bae9c099f08e9c8af4212f8c636ab6c96ed2dc.zip
Please find enclosed a patch that lets you use \c to connect
(optionally) to a new host and port without exiting psql. This eliminates, IMHO, a surprise in that you can now connect to PostgreSQL on a differnt machine from the one where you started your session. This should help people who use psql as an administrative tool. David Fetter
Diffstat (limited to 'doc/src')
-rw-r--r--doc/src/sgml/ref/psql-ref.sgml8
1 files changed, 5 insertions, 3 deletions
diff --git a/doc/src/sgml/ref/psql-ref.sgml b/doc/src/sgml/ref/psql-ref.sgml
index 0c10bdc1cbc..b437bcd87da 100644
--- a/doc/src/sgml/ref/psql-ref.sgml
+++ b/doc/src/sgml/ref/psql-ref.sgml
@@ -1,5 +1,5 @@
<!--
-$PostgreSQL: pgsql/doc/src/sgml/ref/psql-ref.sgml,v 1.157 2005/12/20 00:51:45 tgl Exp $
+$PostgreSQL: pgsql/doc/src/sgml/ref/psql-ref.sgml,v 1.158 2006/02/12 02:54:30 momjian Exp $
PostgreSQL documentation
-->
@@ -693,13 +693,15 @@ testdb=&gt;
</varlistentry>
<varlistentry>
- <term><literal>\connect</literal> (or <literal>\c</literal>) <literal>[ <replaceable class="parameter">dbname</replaceable> [ <replaceable class="parameter">username</replaceable> ] ]</literal></term>
+ <term><literal>\connect</literal> (or <literal>\c</literal>) <literal>[ <replaceable class="parameter">dbname</replaceable> [ <replaceable class="parameter">username</replaceable> ] [ <replaceable class="parameter">host</replaceable> ] [ <replaceable class="parameter">port</replaceable> ] ]</literal></term>
<listitem>
<para>
Establishes a connection to a new database and/or under a user
name. The previous connection is closed. If <replaceable
class="parameter">dbname</replaceable> is <literal>-</literal>
- the current database name is assumed.
+ the current database name is assumed. Similar consideration
+ applies to <replaceable class="parameter">host</replaceable> and
+ <replaceable class="parameter">port</replaceable>.
</para>
<para>