In a suspense processing job, where you can match off items over time, it is important to build in a mechanism to age off histories. This can be implemented by date, either internal item date or cycle number, but there are times when it is important to match off items for a specified number of runs.
You need to store history to use for matching for 30 runs. Due to weekends and holidays, 30 runs span more than 30 days.
Several solutions are possible :
- Use the Suspense Aging Report to see the actual age of the history items, and then manipulate the items in ACR/TransMatch to obtain the desired data.
- Periodically run a job to delete history for items older than 30 days or whatever time frame you want.
- Use the @DATE function to save the current date as an internal item for the original job. With each run, subtract the original date from the current date and delete the item if it is older than a certain number of days, for example, if it is older than 30 days.
- Create a run counter for a key, which allows you to use rules to delete or maintain history when normal history roll-off or roll-off by the number of days will not work.
Complete the following steps to set up a run counter and store history for 30 runs :
1 ) Set up an input source and when you initially extract a key, force a value of zero (0) into an internal item that is the count of days the item has been in history (I-001).
2 ) Create a calculated item that will be stored as the internal item that will add 1 to the original internal item that is the count of days the item had been in history (I-001 + 1).
3 ) Set up your history file as an input source.
4 ) Set up the rules to check the number of days and delete the key value if the value in the calculation equals 30, that is, the number of runs for which you want to store history.