Re: Creating a Pseudocolumn - Mailing list pgsql-hackers

From Martijn van Oosterhout
Subject Re: Creating a Pseudocolumn
Date
Msg-id 20060515153648.GF21506@svana.org
Whole thread Raw
In response to Re: Creating a Pseudocolumn  ("Jonah H. Harris" <jonah.harris@gmail.com>)
Responses Re: Creating a Pseudocolumn
List pgsql-hackers
On Mon, May 15, 2006 at 11:17:41AM -0400, Jonah H. Harris wrote:
> On 5/15/06, Martijn van Oosterhout <kleptog@svana.org> wrote:
> >tableoid is a pseudo-column like you mean, perhaps you should look how
> >that works.
>
> I thought tableoid was a system column with a physical representation
> on the tuple itself?  I don't want any on-disk representation of my
> pseudocolumn... just assigned at runtime similar to rownum.

Tableoid is certainly not stored on disk (waste of space) but retreived
specially whenever someone asks for the tableoid column. See
heap_getsysattr in access/common/heaptuple.c.

All you need to do is decide where you are going to store the level
number and add it as a system attribute (negative attribute number).

Have a nice day,
--
Martijn van Oosterhout   <kleptog@svana.org>   http://svana.org/kleptog/
> From each according to his ability. To each according to his ability to litigate.

pgsql-hackers by date:

Previous
From: "Jonah H. Harris"
Date:
Subject: Re: Creating a Pseudocolumn
Next
From: Bruce Momjian
Date:
Subject: Re: [PORTS] Compiling on 8.1.3 on Openserver 5.05