composite types in 7.3

From: Jeff Davis <list-pgsql-general(at)empires(dot)org>
To: pgsql-general(at)postgresql(dot)org
Subject: composite types in 7.3
Date: 2002-09-30 23:13:08
Message-ID: 200209301613.08468.list-pgsql-general@empires.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general


I tried:
test=> create type mytype as (a int, b text);
CREATE TYPE
test=> create table mytable(x mytype,y int);
CREATE TABLE

It seemed to succeed OK, but did I do anything worthwhile? Since composite
functions don't have input/output functions, I don't know how to actually
create a record in mytable.

Are composite functions supposed to be used in this way? I know that composite
types can be used so that a function can return a record of that type, but is
there any other use?

Regards,
Jeff

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Baurjan Ismagulov 2002-09-30 23:39:04 SERIAL with TTable in cbuilder
Previous Message Tom Lane 2002-09-30 21:26:01 Re: [SQL] CURRENT_TIMESTAMP