| From: | andrew <andrew(dot)ylzhou(at)gmail(dot)com> |
|---|---|
| To: | pgsql-sql(at)postgresql(dot)org |
| Subject: | Re: filtering after join |
| Date: | 2006-01-25 20:13:48 |
| Message-ID: | 29d3b0b90601251213g7f90dac7x9c524544ba72f61b@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-sql |
Sorry for the confusion. This is what i meant. Thanks, Michael.
select *
from (select * from A, B where A.a = B.b) as s
where foo(s) < 2;
On 1/25/06, Peter Eisentraut <peter_e(at)gmx(dot)net> wrote:
> andrew wrote:
> > I want to use a UDF to filter tuples t that are generated after a
> > join. More specifially, I have a UDF foo(record), which computes a
> > value for a given tuple. I can do the filtering before the join.
> > e.g.:
> >
> > select * from A, B where foo(A)<2 and A.a=B.b;
>
> What makes you think that the filtering happens before the join here?
> And why would it matter? The results should be all the same.
>
> --
> Peter Eisentraut
> http://developer.postgresql.org/~petere/
>
--
andrew
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Mario Splivalo | 2006-01-26 07:08:30 | Re: Changing the transaction isolation level within the |
| Previous Message | Peter Eisentraut | 2006-01-25 19:11:13 | Re: filtering after join |