Table 212 Command Line Options to Use When Invoking psql

Option

-U username -W

Action

Connects to the remote host hostname (if the database server isn't located on the local system).

Specifies n as the number of the port that the client should connect to. Note that this is a lowercase p.

Connects to the database as the user username.

Prompts for a password after connecting to the database. In PostgreSQL 7 and later, password prompting is automatic if the server requests a password after a connection has been established.

Displays a help message.

Several more options are available in addition to those listed in Table 21.2. See the psql's man page for details on all the available options.

Was this article helpful?

0 0

Post a comment