O'Reilly logo
  • Bill Levien thinks this is interesting:

The PSQL command lineIf you are interested in running commands other than those available in the CLI interface, you can install the standard Postgres PSQL command-line tools. The Amazon CLI tool is clearly focused on management functionality and not on the execution of queries. To connect using the psql command line, you need three values: -h (hostname), -p (port), and -U (user). You will then be prompted for the password as shown in the following command:# psql -h <Endpoint> -p 5439 -U <user> There are many other options to pass in files, how you wish to have the output formatted, or setting variables as described here.


Cover of Getting Started with Amazon Redshift


Even outside of AWS, the PSQL command line tools are super useful for pulling data from a DB for small ad-hoc reporting tools, especially managing/manipulating queries in plain text files using the -F option