Re: Multiple Inheritance

Поиск
Список
Период
Сортировка
От Oliver Elphick
Тема Re: Multiple Inheritance
Дата
Msg-id 200105030910.f439AaiW028738@linda.lfix.co.uk
обсуждение исходный текст
Ответ на Multiple Inheritance  (tankgirl@worldonline.es)
Ответы Re: Multiple Inheritance  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-general
tankgirl@worldonline.es wrote:
  >  Hi everyone,
  >
  >  I have found out that Postgres provides inheritance between tables.
  >
  >  I wonder if 'multiple inheritance' can be implemented. I mean if
  >a child table may have more than one parent table.
  >  And if this is possible what sql syntax does it follow.

It's in the man page for create_table:

       CREATE [ TEMPORARY | TEMP ] TABLE table_name (
           { column_name type [ column_constraint [ ... ] ]
             | table_constraint }  [, ... ]
           ) [ INHERITS ( inherited_table [, ... ] ) ]
...
       inherited_table
              The optional INHERITS clause specifies  a  list  of
              table  names  from  which  this table automatically
              inherits all fields.  If any inherited  field  name
              appears  more than once, Postgres reports an error.
              Postgres automatically allows the created table  to
              inherit functions on tables above it in the inheri­
              tance hierarchy.


--
Oliver Elphick                                Oliver.Elphick@lfix.co.uk
Isle of Wight                              http://www.lfix.co.uk/oliver
PGP: 1024R/32B8FAA1: 97 EA 1D 47 72 3F 28 47  6B 7E 39 CC 56 E4 C1 47
GPG: 1024D/3E1D0C1C: CA12 09E0 E8D5 8870 5839  932A 614D 4C34 3E1D 0C1C
                 ========================================
     "Rejoice with them that do rejoice, and weep with them
      that weep."            Romans 12:15



В списке pgsql-general по дате отправления:

Предыдущее
От: tankgirl@worldonline.es
Дата:
Сообщение: Multiple Inheritance
Следующее
От: jdassen@cistron.nl (J.H.M. Dassen (Ray))
Дата:
Сообщение: Re: Ideal hardware configuration for pgsql