Re: postgresql system column errors

From: Martijn van Oosterhout <kleptog(at)svana(dot)org>
To: Ashish Mahabal <aam(at)astro(dot)caltech(dot)edu>
Cc: Mark Gibson <gibsonm(at)cromwell(dot)co(dot)uk>, Inoue(at)tpf(dot)co(dot)jp, pgsql-general(at)postgresql(dot)org
Subject: Re: postgresql system column errors
Date: 2004-02-20 22:48:38
Message-ID: 20040220224838.GA28711@svana.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Tue, Feb 17, 2004 at 11:15:13AM -0800, Ashish Mahabal wrote:
>
> Thanx Mark.
>
> Thats what I ended up doing. But it seems silly that the name space for
> system columns and user columns are not separate. Its just like saying
> that you can not have the same column name in 2 different tables.
>
> Just like I can say table1.myCol and table2.myCol, there should have been
> a way to say system.xmin and myTable.xmin, the default being myTable.xmin
> when I am doing stuff with myTable. Whereever xmin gets used currently,
> the source could explicitely say system.xmin. Anyway. hope that is done in
> some future version.

I think you're missing something. Every table has the xmin, xmax, cmin, cmax
and sometimes oid columns. They're not only in the system tables. These
columns are what makes transactions work and they exist for every record.

I hope you're not suggesting a move to myTable.system.xmin ?

Pick a table and do: select xmin,xmax,cmin,cmax from <table>

What you're asking is to have the same column name twice in a single table,
which is obviously silly.
--
Martijn van Oosterhout <kleptog(at)svana(dot)org> http://svana.org/kleptog/
> If the Catholic church can survive the printing press, science fiction
> will certainly weather the advent of bookwarez.
> http://craphound.com/ebooksneitherenorbooks.txt - Cory Doctorow

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Martijn van Oosterhout 2004-02-20 22:51:20 Re: Cascade delete triggers change user credentials
Previous Message Bill Moran 2004-02-20 22:39:02 Re: Problems with plpgsql and FOR loops