Hi
I urgently need help on writing a query.
I have two tables. One contains purchases by product and date, the other table contains standard prices by product and effective date.
I need to return the relevant standard price for each purchase. See Example Below
Table A: Purchases
ProductCode Date
10A 1st Jan 05
10A 8th Feb 05
10A 12th Feb 05
etc
Table B: Agreed Product Price
ProductCode EffectiveDate Price
10A 1st Dec 04 £10.00
10A 5th Jan 05 £10.50
10A 11th Feb 05 £11.25
etc
Query
ProductCode Date Standard Price
10A 1st Jan £10.00 (Price @ 1/12/4)
10A 8th Feb £10.50 (Price @ 5/1/5)
10A 12th Feb £11.25 (Price @ 11/2/5)
How do you do it?
This is doing my head in.
Somebody PLEASE help me!!!!!!
Thanks
JASON
I urgently need help on writing a query.
I have two tables. One contains purchases by product and date, the other table contains standard prices by product and effective date.
I need to return the relevant standard price for each purchase. See Example Below
Table A: Purchases
ProductCode Date
10A 1st Jan 05
10A 8th Feb 05
10A 12th Feb 05
etc
Table B: Agreed Product Price
ProductCode EffectiveDate Price
10A 1st Dec 04 £10.00
10A 5th Jan 05 £10.50
10A 11th Feb 05 £11.25
etc
Query
ProductCode Date Standard Price
10A 1st Jan £10.00 (Price @ 1/12/4)
10A 8th Feb £10.50 (Price @ 5/1/5)
10A 12th Feb £11.25 (Price @ 11/2/5)
How do you do it?
This is doing my head in.
Somebody PLEASE help me!!!!!!
Thanks
JASON