This is a basic SQL client that will let you connect to a database so long as you have:

a console login (shell-prompt)

a Java run-time (Java 7 or later)

a JDBC driver for your database (PostgreSQL support is built-in)

a user-name and password for a database user

In particular, Squelch does not need a graphical display; it's intended for cases where you don't have access to one.
If you do have a graphical UI, then you'll probably be much happier using a fancier tool; personally, I like
Squirrel SQL a lot.

To use it,

Download this JAR file,
which contains both the Squelch code and its dependencies.

If you are using Oracle, MS SQL Server, or MySQL, you'll need to download an appropriate JDBC JAR separately.
(The PostgreSQL JDBC driver is already included inside Squelch's JAR.)