psql console
Start a Windows command console or powershell
Connect to PostgreSQL with
psql -U postgres
The password is CompSys2025!

List databases
\list
or
\l
Connect to database bookshop
\c bookshop
Display tables in database bookshop
\dt
or
\dt+
Show table schemas
\d tablename

Run your SQL statements, such as
SELECT * from books

Last updated