Psql has special commands that start with a backslash. They're not SQL. They're shortcuts that describe the database, so you don't have to remember table details.
Backslash d t lists all the tables. Backslash d, then a table name, describes that table. Run it. Every table, then the staff columns with their types, keys and links.
query.sqlsql
\dt\d staff
Output
List of tables
Schema | Name | Type | Owner
--------+-------------+-------+----------
public | books | table | postgres
public | customers | table | postgres
public | order_items | table | postgres
public | orders | table | postgres
public | reviews | table | postgres
public | staff | table | postgres
(6 rows)
Table "public.staff"
Column | Type | Collation | Nullable | Default
------------+---------+-----------+----------+----------------------------------
staff_id | integer | | not null | generated by default as identity
name | text | | not null |
role | text | | not null |
manager_id | integer | | |
salary | integer | | not null |
Indexes:
"staff_pkey" PRIMARY KEY, btree (staff_id)
Foreign-key constraints:
"staff_manager_id_fkey" FOREIGN KEY (manager_id) REFERENCES staff(staff_id)
Referenced by:
TABLE "staff" CONSTRAINT "staff_manager_id_fkey" FOREIGN KEY (manager_id) REFERENCES
staff(staff_id)
Backslash l lists databases. Backslash c connects to another one. Backslash d n lists schemas, and backslash d f lists functions. Backslash x switches to expanded output, for wide rows. And backslash q quits.