Re: Getting one row for each subquery row...? - Mailing list pgsql-sql

From Együd Csaba
Subject Re: Getting one row for each subquery row...?
Date
Msg-id 009201c336f9$fdb9ba70$230a0a0a@compaq
Whole thread Raw
In response to Getting one row for each subquery row...?  (Együd Csaba <csegyud@freemail.hu>)
List pgsql-sql
Thank you Tomasz,
this last one seems to be good - with a little change.

select distinct t_stockchanges.productid, t_productgroups.name as pgroup
from t_stockchanges
join t_prod_in_pgr using (productid)
join t_productgroups on (t_productgroups.id=productgroupid);

Thank you again.
By,
-- Csaba

> Sorry, if you want all combination of grups and products, you need to
rewrite
> your query:
>
> select
>   t_stockchanges.productid,
>   t_productgroups.name as pgroup
> from
>   t_stockchanges
>   join t_prod_in using (productid)
>   join t_productgroups on (id=productgroupid)
>
> or something like this.
>
> Tomasz
>



---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.489 / Virus Database: 288 - Release Date: 2003. 06. 10.



pgsql-sql by date:

Previous
From: Tomasz Myrta
Date:
Subject: Re: Getting one row for each subquery row...?
Next
From: "Anagha Joshi"
Date:
Subject: Re: [ADMIN] Latest transcation