describe a table in postgresql code example
Example 1: postgre describe table
SELECT
table_name,
column_name,
data_type
FROM
information_schema.columns
WHERE
table_name = 'city';
Example 2: show details of table postgres
postgres=# \d tablename;