Re: Query with multiple tables
patrick.sparks_at_gmail.com
Date: 10/20/04
- Previous message: David Portas: "Re: Help with converting MS SQL To MS Access"
- In reply to: Don: "Re: Query with multiple tables"
- Next in thread: Don: "Re: Query with multiple tables"
- Reply: Don: "Re: Query with multiple tables"
- Messages sorted by: [ date ] [ thread ]
Date: 19 Oct 2004 19:03:42 -0700
That query is much too complicated for what you're trying to do. Try
this:
SELECT
t1.item
, t1.description
, t2.location
, t2.qty_on_hand AS qty_on_hand
, SUM(t3.sales) AS ytd_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
- Previous message: David Portas: "Re: Help with converting MS SQL To MS Access"
- In reply to: Don: "Re: Query with multiple tables"
- Next in thread: Don: "Re: Query with multiple tables"
- Reply: Don: "Re: Query with multiple tables"
- Messages sorted by: [ date ] [ thread ]
Loading