Hello,
I have a database table that I can query for store items. Each item in the table has an associated purchase date and an associated store. How would you suggest writing a PLSQL script that first sorts the data in the table by store, item and purchase date and then only prints out only those stores and items with purchase dates within 3 days of each other. Thanks in advance.
-Cassie
Store: A
--Item: 123
----Purchase Date: 01-Jan-2011
--Item: 456
----Purchase Date: 02-Jan-2011
Note that Item: 789 would not be displayed because the purchase date is 07-Jan-2011
I have a database table that I can query for store items. Each item in the table has an associated purchase date and an associated store. How would you suggest writing a PLSQL script that first sorts the data in the table by store, item and purchase date and then only prints out only those stores and items with purchase dates within 3 days of each other. Thanks in advance.
-Cassie
Store: A
--Item: 123
----Purchase Date: 01-Jan-2011
--Item: 456
----Purchase Date: 02-Jan-2011
Note that Item: 789 would not be displayed because the purchase date is 07-Jan-2011