Re: COMPUTED BY fields or equivalent?

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Paul Ganainm <paulsnewsgroups(at)hotmail(dot)com>
Cc: pgsql-novice(at)postgresql(dot)org
Subject: Re: COMPUTED BY fields or equivalent?
Date: 2003-12-06 15:33:51
Message-ID: 13551.1070724831@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

Paul Ganainm <paulsnewsgroups(at)hotmail(dot)com> writes:
> I use Interbase (starting on PostgreSQL) which has a concept of

> CREATE TABLE My_Table
> (
> First_Name VARCHAR(15),
> Last_Name VARCHAR(15),
> Full_Name VARCHAR(30) COMPUTED BY(First_Name || ' ' || Last_Name)
> }

You could do that with a view (if you don't want the derived field to be
physically stored on disk) or with a trigger (if you do).

regards, tom lane

In response to

Responses

Browse pgsql-novice by date

  From Date Subject
Next Message NK 2003-12-07 00:49:40 Help! Parser Stage: Get The Columns Of the Table
Previous Message epz 2003-12-06 14:11:21 newbie needs help seting up for gentoo