Re: Listing Child Tables of a Particular Parent - Mailing list pgsql-novice

From Tom Lane
Subject Re: Listing Child Tables of a Particular Parent
Date
Msg-id 2130.1151000884@sss.pgh.pa.us
Whole thread Raw
In response to Listing Child Tables of a Particular Parent  ("Garcia, Joshua" <Joshua.Garcia@xerox.com>)
List pgsql-novice
"Garcia, Joshua" <Joshua.Garcia@xerox.com> writes:
> I've been trying to figure out how to get a list of all the child tables
> for a particular parent table.

You'd need to join pg_inherits to pg_class (twice).  See
http://www.postgresql.org/docs/8.1/static/catalogs.html
(adjust link in the obvious way for older PG versions)

            regards, tom lane

pgsql-novice by date:

Previous
From: "Garcia, Joshua"
Date:
Subject: Listing Child Tables of a Particular Parent
Next
From:
Date:
Subject: Copy Data Question