![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
Hi, Hoping to do this in one query without writing code. Got an order table: Customer ID Order Date Status 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.... |
#3
| |||
| |||
|
|
Hi, Hoping to do this in one query without writing code. Got an order table: Customer ID Order Date Status 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.... |
#4
| |||
| |||
|
|
Hi, Hoping to do this in one query without writing code. Got an order table: Customer ID Order Date Status 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.... |
![]() |
| Thread Tools | |
| Display Modes | |
| |