psql is a very powerful command-line tool and is superior to similar utilities available with other databases. For example, if we are not sure about the name of a table (did I name it
employees?), the only option available in Oracle's SQL* Plus is to query a data dictionary view (such as
tab) with a
LIKE filter. In psql, we can just type
\dt e and hit Tab twice to get the list of tables starting with
e. In short, psql supports tab completion—a nifty feature that is a great productivity booster. Now that it sounds interesting, let's look at more.
psql --help command lists all possible options that can be used with psql. We might want to use psql to ...