This script allows you to take two date fields and perform three different extracts:
It will then summarize the findings based on year and month. You can select which date field to use for obtaining the date and month information.
'* Script: Payment date vs due date.iss
'* Author: Brian Element - email@example.com
'* Date: Oct 9, 2012
'* Purpose: This script will take two date fields and create up to 3 files, one file in which one date is less than the other, another in which the two date fields are equal and the 3rd in which one date field is larger than the other. The user can choose one or all 3 of these files. Finally the script summarizes the newly created file by year and month, the user can decide to use the 1st or 2nd date field or both for the summarizations.
When you start the script the following dialog will be displayed.
You must first select the IDEA file (that has already been imported) that you wish to work on. This file must contain at least one numeric field (the amount field) and two date fields (the payment date and due date fields). Once the IDEA file has been selected you can select the fields you wish to analyze.
There are three ways to analyze the file and you can perform one, two or three of these at the same time. The first has analysis as the first date field less than the second, the next has both date fields equal and the third as the first date field greater than the first. Each analysis will create its own IDEA file. The files will then be summarzied by year and month based on the due date, payment date or both.
This script will potentially create 2 to 9 files depending on your selections.
The idea was suggested in the IDEAScripting forum. The suggestion was to compare the payment date with the due date in an accounts payable file but this script could be used to compare any two date fields.
If you have any questions, suggestions or comments you can contact me at the above email or post at ideascripting.com.