I am new to SQL and I wonder if this can be done.
I have 3 tables:
Table "SITES"
--------------------------------------
SITEID
--------------------------------------
S1
S2
Table "BALANCE"
--------------------------------------
PRODUCTID SITEID QTY
--------------------------------------
Apple S1 120
Apple S2 50
Egg S1 60
Egg S2 0
Table "PRODUCTS"
--------------------------------------
PRODUCTID
--------------------------------------
Apple
Egg
How do I put together a query and generate a recordset like:
--------------------------------------
PRODUCTID S1 S2
--------------------------------------
APPLE 120 50
Egg 60 0
I am new to SQL, please enlight me.
ray:
Million thanks in advance. Peace.
Kevin
I have 3 tables:
Table "SITES"
--------------------------------------
SITEID
--------------------------------------
S1
S2
Table "BALANCE"
--------------------------------------
PRODUCTID SITEID QTY
--------------------------------------
Apple S1 120
Apple S2 50
Egg S1 60
Egg S2 0
Table "PRODUCTS"
--------------------------------------
PRODUCTID
--------------------------------------
Apple
Egg
How do I put together a query and generate a recordset like:
--------------------------------------
PRODUCTID S1 S2
--------------------------------------
APPLE 120 50
Egg 60 0
I am new to SQL, please enlight me.
Million thanks in advance. Peace.
Kevin