Re: Specifying Rowtypes

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Curt Sampson <cjs(at)cynic(dot)net>
Cc: PostgreSQL Development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Specifying Rowtypes
Date: 2003-01-29 08:46:54
Message-ID: 21429.1043830014@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Curt Sampson <cjs(at)cynic(dot)net> writes:
> So currently the only way to specify a row type is by using a table,

No, as of 7.3 there's CREATE TYPE foo AS (column list). But ...

> This is returning a row that (to my mind) doesn't match the type of the
> table above, because it's returning null for non-nullable columns:

The current behavior of a rowtype doesn't include any constraint checks.
Feel free to design a solution ...

regards, tom lane

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Curt Sampson 2003-01-29 10:18:32 Re: Specifying Rowtypes
Previous Message Oleg Bartunov 2003-01-29 08:37:13 Re: tsearch comments