Report with Several Subsummaries
I have created the Deviation Report with five subsummaries that is not showing the data correctly.
I am asking help to troubleshooting it.
I am developping a project that manages Deviations reports. So the basic structure of the DEVIATION table is the following:
DeviationCount (Summary = Count of __kp_Deviation)
Total (Calculation = Get(TotalRecordCount))
z_DateDeviationMonth (Calculation = Month(DeviationDate))
z_DateDeviationMonthName (Calculation = MonthName(DeviationDate))
z_DateDeviationYear (Calculation = Year(DeviationDate))
The Deviation Report is created by the Report Script attached to the Report Button that is on the the Deviation_Detail Layout based on the DEVIATION Table.
The Report Script contains, apart from other script steps, the following Sort Records script step:
and sorts in Ascending Order
Deviation Report Layout Structure
The Deviation Report is created from the Deviation Report layout based on the DEVIATION Table
The Deviation Report layout has the following structure:
HEADER that cointains the "Deviation Report" text and "Total" text
Sub_summary by z_DateDeviationYear (Leading) that contains the folllowing fields:
DEVIATION::z_DateDeviationYear and DEVIATION::DeviationCount
Sub_summary by z_Quarter (Leading) that contains the folllowing fields:
DEVIATION::z_Quarter and DEVIATION::DeviationCount
Sub_summary by z_DateDeviationMonthDate (Leading) that contains the folllowing fields:
DEVIATION::z_DateDeviationMonthDate and DEVIATION::DeviationCount
Sub_summary by DeviationOrigin (Leading) that contains the folllowing fields:
DEVIATION::DeviationOrigin and DEVIATION::DeviationCount
Sub_summary by DeviationSubject (Leading) that contains the folllowing fields:
DEVIATION::DeviationSubject and DEVIATION::DeviationCount
Deviation Report Structure Purpose
The purpose of the Deviation Report is to come out with the following basic report:
Deviation Report Total
Year Number of Deviations per Year
Quarter Number of Deviations per Quarter
Month Number of Deviations per Month
Deviation Origin Number of Deviations per type of Deviation Origin
Deviation Subject Number of Deviations per type of Deviation Subject
In order to troubleshoot it, my first question is related to the suitability of the calculation on which it is based the DEVIATION::DeviationCount field. Should I use the DEVIATION::__kp_Deviation field or should I use another field?
I wonder what happens to DEVIATION::DeviationCount field when the user erases a record. In this case the generated DEVIATION::__kp_Deviation value stays in the database although it no longer has any significance for the updated database. Am I right?
As you can see from the attached picture, there is something wrong because for the OOS Deviation in the Equipment that was reported on February 2009 is placed under the Second Quarter instead of under the first Quarter as it should.
Help on how to sort this out is much needed and appreciated.