Re: Query with multiple tables

patrick.sparks_at_gmail.com
Date: 10/20/04


Date: 19 Oct 2004 19:05:20 -0700

Try this:
SELECT
t1.Item
, t1.description
, t2.location
, t2.qty_on_hand
, sum(t3.sales)
from t1
inner join t2 on t1.item = t2.item
inner join t3 on t2.item = t3.item and t2.location = t3.location
group by
t1.Item
  , t1.description
  , t2.location
  , t2.qty_on_hand


Loading