PSQL Select not working – or other simple commands not working
Working with command line postgres tool psql and having an issue?
Why doesn’t the psql command show the simple select query?
PSQL select not working is a problem that can happen in either of the following scenarios:
- Are you on the right database?
Chances are you might not be on the right database at all and the relation you are trying to find might not be there at all:Check if you are on the right database.
Run the command\l
to see the available databases.How to connect to the postgres database from the list?
Use the command\c database_name
Let’s say the database name is inventory then:\c inventory
will connect you to the right database