From: | Luis Sousa <llsousa(at)ualg(dot)pt> |
---|---|
To: | Peter Eisentraut <peter_e(at)gmx(dot)net> |
Cc: | pgsql sql Mailing List <pgsql-sql(at)postgresql(dot)org> |
Subject: | Re: Hidden Select |
Date: | 2001-06-11 16:27:37 |
Message-ID: | 3B24F179.F2695957@ualg.pt |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-sql |
Suposing your example:
Now i want to do a query to the view like this:
SELECT * FROM C WHERE id=1;
I whant to chose the id, but that id isn't in my select list !!!?????
I hope you understand what i mean
Best regards
Luis Sousa
Peter Eisentraut wrote:
> Luis Sousa writes:
>
> > I have a query that joins several table with some restrictions.
> > I want to take out those restrictions from the query and create a view
> > that does not show the fields that are used to restrict the data, but in
> > some way, i can restrict that data when i call the view.
>
> Do you mean like this?
>
> create table A (id int, content text);
> create table B (id int, stuff numeric);
> create view C as select A.content, B.stuff from A, B where A.id = B.id;
>
> --
> Peter Eisentraut peter_e(at)gmx(dot)net http://funkturm.homeip.net/~peter
From | Date | Subject | |
---|---|---|---|
Next Message | Peter Eisentraut | 2001-06-11 16:34:42 | Re: Hidden Select |
Previous Message | Najm Hashmi | 2001-06-11 15:54:43 | Bit Mapping operation |