PostgreSQL 18 · Inspecting the database
Describe a table
Show a table's columns, types, indexes and constraints.
\d users
Official PostgreSQL 18 documentation
More inspecting the database commands
All inspecting the database commands · PostgreSQL 18 cheatsheet