Re: create table and data types

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Maciej Piekielniak <piechcio(at)isb(dot)com(dot)pl>
Cc: pgsql-sql(at)postgresql(dot)org
Subject: Re: create table and data types
Date: 2006-02-14 22:06:34
Message-ID: 23215.1139954794@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

Maciej Piekielniak <piechcio(at)isb(dot)com(dot)pl> writes:
> Is anybody know how create field in a new table with data type accuiring from a field in other table?

Sorry, the %TYPE syntax only works in function declarations at the
moment.

It could possibly be made to work in table declarations --- there are
syntactic conflicts with allowing it in general, but I'm not sure that
objection applies to table declarations. But it's not there today.

regards, tom lane

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message Ken Hill 2006-02-14 22:42:02 Re: create table and data types
Previous Message Maciej Piekielniak 2006-02-14 22:03:17 Re: create table and data types