To describe created table schema in PostgreSQL we need to run command on psql CLI
SYNTAX:
/d+ <table_name>
EX:
postgres=# \d+ student Table "public.student" Column | Type | Modifiers | Storage | Stats target | Description --------+-----------------------+-----------+----------+--------------+------------- id | integer | not null | plain | | name | character varying(25) | | extended | | age | integer | | plain | | gender | character(1) | | extended | | Indexes: "student_pkey" PRIMARY KEY, btree (id) postgres=# \d+ mentor Table "public.mentor" Column | Type | Modifiers | Storage | Stats target | Description ---------+-----------------------+-----------+----------+--------------+------------- m_id | integer | not null | plain | | name | character varying(25) | | extended | | subject | character varying(25) | | extended | | Indexes: "mentor_pkey" PRIMARY KEY, btree (m_id)
Above command explaining table structure their column name data types and constraints.