I'm having a hard time wrapping my head around this one. I need to find out which products have not shipped in the last 2 years, 1 year and 6 months (three queries) and then update the prices based on a percentage.
The tables I am using are:
BX tabele has SHIPDATE and ORDERNO
BXCNT table has ORDERNO and STOCKNUMBER
STOCK table has STOCKNUMBER and PRICE
The BXCNT table is like an order detail that contains all the stock numbers inside the order. That is the way I tie the shipdate to the number
The date format looks like this: 1999-11-18 00:00:00.000
So I want to select STOCKNUMBER and update the PRICE (price * .75) if SHIPDATE > 2 years
Hope that makes sense. Thank you for any help and information.