How to make user-defined data types?

From: <drevil(at)sidereal(dot)kz>
To: pgsql-general(at)postgresql(dot)org
Subject: How to make user-defined data types?
Date: 2000-12-16 08:02:02
Message-ID: 20001216080202.8495.qmail@mailhost.sidereal.kz
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general


I know it is possible to define a new data type which is a composite
of PG native types, but there seems to be little or no documentation
(that I can find) about how to do this. For example, I have a lot of
data in the form of an address, which contains address-line-1,
address-line-2, city, province, country, and postal code. I want to
put all of these data into a single type, so I can pass it back and
forth to pl/pgsql functions as just one argument. I'm having to send
so many arguments that I am running into the 16 argument limit, and
anyway, it would be much easier to handle if I could just define an
address type.

Any information would be appreciated, including references to
websites.

Thanks

Browse pgsql-general by date

  From Date Subject
Next Message Ing. Michael Petroni 2000-12-16 11:56:19 Concurrent transaction problem
Previous Message Guang Mei 2000-12-16 04:27:02 Does postgresql support storage clause when creating tables