Re: [HACKERS] It would be nice if this could be fixed... - Mailing list pgsql-hackers

From The Hermit Hacker
Subject Re: [HACKERS] It would be nice if this could be fixed...
Date
Msg-id Pine.BSF.4.05.9904261339070.47191-100000@thelab.hub.org
Whole thread Raw
In response to Re: [HACKERS] It would be nice if this could be fixed...  (jwieck@debis.com (Jan Wieck))
List pgsql-hackers
On Mon, 26 Apr 1999, Jan Wieck wrote:

> Marc G. Fournier wrote:
> 
> >
> > On Sat, 17 Apr 1999, Chris Bitmead wrote:
> >
> > >
> > > I'm not sure what you're getting at. Yep, you can include the oid field
> > > if you rename it, but it would be nice if you could leave it alone.
> > >
> > > A typical scenario is that you create some table and start using it.
> > > Then you find you need some derived field (like quantity*price AS total)
> > > or something. So you may rename say product table to productold, and
> > > create a product view that is SELECT *, quantity*price AS total from
> > > productold.
> > >
> > > The problem then arises if your code uses oid, because a view can't have
> > > a field called oid. I'm advocating that you be allowed to create views
> > > that have a field called oid to avoid this problem.
> >
> > As D'Arcy did ask...which oid would you want used?  The one from table a,
> > or from Table b?  They are two distinctly different numbers...the VIEW
> > itself doesn't have an OID assigned to its rows, only the physical tables
> > themselves...
> 
>     Not  exactly,  because in his example there is only one table
>     used in the view. But I wonder what an OID from a view  might

Wait, I thought his SELECT had a 'FROM a,b' clause in it...no? *raised
eyebrow*  If not, I misread, apologies...

Marc G. Fournier                   ICQ#7615664               IRC Nick: Scrappy
Systems Administrator @ hub.org 
primary: scrappy@hub.org           secondary: scrappy@{freebsd|postgresql}.org 



pgsql-hackers by date:

Previous
From: Clayton Cottingham
Date:
Subject: [Fwd: 6.5beta]
Next
From: Taral
Date:
Subject: Re: CORBA again. (was: light dawns: serious bug in FE/BE protocol handling)