When scripting appends, you can ensure that duplicate records will not occur even if the script is ran multiple times for the same period or other categorization.
For example, append the following fields to a yearly file in a script intended to be ran monthly: Month, Location, Average_Lbs.
It would look similar to this:
EXTRACT Month Location Average_Lbs TO “A_Year_Avg_Per_Lb.fil” APPEND OPEN
If this is ran more than once in the same month, the monthly information would appear more than once. Add a summarization with no subtotals to all appends to eliminate this problem.
SUMMARIZE ON Month Location OTHER Average_Lbs TO “Final_A_Year_Avg_Per_Lb.fil” PRESORT