Select previous records
Date: Thu, 7 May 2009 17:36:37 -0700 (PDT)
Hoping to do this in one query without writing code.
Got an order table:
Customer places an order, status becomes 'Active' and 1 year later the customer can re-new or cancel. If customer renews then current order goes to 'Complete' and new order is placed with 'Active'.
I need to know, for any given date, is current 'Active' order result of a 'renew'. So, is there an order 1 year ago.
Not sure how this is done, maybe with some analytical stuff? Basically take order from now, look back 1 year and see if there is an order there.....
Possible without PL/SQL I hope.... Received on Thu May 07 2009 - 19:36:37 CDT