pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Gianvito Pio <pio.gianvito@gmail.com>
To: pgsql-sql@postgresql.org
Subject: Type inheritance
Date: Fri, 5 Jun 2009 12:30:08 +0200
Message-ID: <5eca56860906050330w6171b327k95881b13c4dca466@mail.gmail.com> (raw)

Hi all,
I just want to ask you if it's possible to define sub types in PostgreSQL
(Type inheritance). I found that table inheritance is possible...but I'd
like to do it on types.

Example:
define a type Value and two subtypes Temperature and Humidity and then
define a table that has an attribute of Value type (that can accept both
specialized types).

Thanks

view thread (13+ messages)  latest in thread

Message-ID: <5eca56860906050330w6171b327k95881b13c4dca466@mail.gmail.com>
Permalink:  ../5eca56860906050330w6171b327k95881b13c4dca466@mail.gmail.com/
Also on:    postgresql.org/message-id/5eca56860906050330w6171b327k95881b13c4dca466@mail.gmail.com

 · 

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 using the --to and --cc options:
  reply via email

  To: pgsql-sql@postgresql.org
  Cc: pio.gianvito@gmail.com
  Subject: Re: Type inheritance
  In-Reply-To: <5eca56860906050330w6171b327k95881b13c4dca466@mail.gmail.com>

* 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