Skip site navigation (1) Skip section navigation (2)

Re: Querying a parent table's child schemas

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Matthews, James" <jmatthews(at)Railpower(dot)com>
Cc: pgsql-novice(at)postgresql(dot)org
Subject: Re: Querying a parent table's child schemas
Date: 2007-08-30 16:01:14
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-novice
"Matthews, James" <jmatthews(at)Railpower(dot)com> writes:
>       I was wondering if there was a way to SELECT from a parent table
> and display the schema associated with a child table's data.

It's not entirely clear to me which meaning of "schema" you have in
mind, but perhaps the tableoid system column would help you?  That
lets you determine which child table the row really came from,
and then you can join to the system catalogs to get whatever data
you are actually after.

			regards, tom lane

In response to


pgsql-novice by date

Next:From: Mija LeeDate: 2007-08-30 17:15:22
Subject: Could not remove file messages
Previous:From: Matthews, JamesDate: 2007-08-30 13:30:56
Subject: Querying a parent table's child schemas

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group