Re: SQL statement : list table details - Mailing list pgsql-general

From Dino Hoboloney
Subject Re: SQL statement : list table details
Date
Msg-id a60ok0$noq$1@jupiter.hub.org
Whole thread Raw
In response to SQL statement : list table details  ("Dino Hoboloney" <whatever@whatever.com>)
List pgsql-general
think I answered my own question ....

SELECT a.attnum, a.attname AS field, a.atttypid AS column_type, a.atttypmod
AS type_specific, c.relname AS table_name FROM pg_class c, pg_attribute a
WHERE c.relname NOT LIKE 'pg%' AND relkind = 'r' AND a.attnum > 0 AND
a.attrelid = c.oid ORDER BY table_name, attnum;

this will now list column_type, and type_specific which is type-specific
data such as varchar length.



pgsql-general by date:

Previous
From: "Tim Finch, FosterFinch Ltd"
Date:
Subject: PGSTAT Error from Postmaster
Next
From: "Patrick L. Nolan"
Date:
Subject: What are functional indices good for?