Re: forgot the structure of a composite type

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Manal Helal <manalorama(at)gmail(dot)com>
Cc: pgsql-admin(at)postgresql(dot)org
Subject: Re: forgot the structure of a composite type
Date: 2009-03-30 02:45:01
Message-ID: 10198.1238381101@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

Manal Helal <manalorama(at)gmail(dot)com> writes:
> I defined a composite type and forgot its structure, data fields names
> and data types. Is there any command that can define that for me?

psql's \d command, for one.

regression=# create type fooey as (f1 int, f2 text);
CREATE TYPE
regression=# \d fooey
Composite type "public.fooey"
Column | Type
--------+---------
f1 | integer
f2 | text

regards, tom lane

In response to

Browse pgsql-admin by date

  From Date Subject
Next Message fatih ozturk 2009-03-30 08:34:52 Partitionin with check functions
Previous Message Manal Helal 2009-03-30 02:40:29 forgot the structure of a composite type