pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Thomas Swan <tswan@olemiss.edu>
To: pgsql-sql@hub.org
Subject: Finding the names of inheriting classes
Date: Wed, 28 Jun 2000 13:50:45 -0500
Message-ID: <4.3.2.7.2.20000628135033.01f37368@sunset.backbone.olemiss.edu> (raw)


This is actually two problems...

I'm at a loss on how identify or get the names of children of a parent class.

For example, I have three children of a parent class Cities : Big_Cities, 
Little_Cities, Not_Cities.   I know that I can do a select * from Cities* 
and get all rows from Cities and Cities' children.

For the first question, is there a way I can get the names of the tables 
(classes) that inherit from a parent class?
For example, getting the names of the tables 
"Big_Cities","Little_Cities",and "Not_Cities" from a statement asking what 
are the children of tables (class) Cities.

The second question revolves around the select * from Cities*.

If Cities has a "name" column and Big_Cities has a "population" column 
added and I do a select * from Cities* the resulting table only has the 
"name" column.  Is there a way to get a table that has all the columns (not 
just the ones in common) and put nulls in the columns for which there is no 
information or data?
-
- Thomas Swan
- ________________________________________
- Graduate Student  - Computer Science
- The University of Mississippi
-
- "People can be sorted into two fundamental groups,
- those that divide people into two groups and
- those that don't."

view thread (3+ messages)  latest in thread

Message-ID: <4.3.2.7.2.20000628135033.01f37368@sunset.backbone.olemiss.edu>
Permalink:  ../4.3.2.7.2.20000628135033.01f37368@sunset.backbone.olemiss.edu/
Also on:    postgresql.org/message-id/4.3.2.7.2.20000628135033.01f37368@sunset.backbone.olemiss.edu

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-sql@postgresql.org
  Cc: tswan@olemiss.edu, pgsql-sql@hub.org
  Subject: Re: Finding the names of inheriting classes
  In-Reply-To: <4.3.2.7.2.20000628135033.01f37368@sunset.backbone.olemiss.edu>
  References: <4.3.2.7.2.20000628135033.01f37368@sunset.backbone.olemiss.edu>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox