I have a need similar to this:
It's similar in that I want a report-level average for various ambulance response intervals (turnout time, drive time, etc.), as well as the following report-level summaries: minimum, maximum, median, 90th percentile, and (3 * standard deviation) + average (to identify statistical outliers).
The data come from two tables named Incident and Manpower. The Incident table includes data about the overall event and the Manpower table includes individual time stamps for individual units (fire trucks, ambulances, etc). All time stamps from start to finish are logged in Manpower for every unit, along with individual codes to identify what each specific time stamp represents (unit dispatched, unit enroute, etc.).
The report includes these fields (among others):
[ul]
Incident.Event_Number
Incident.Incident_PK
Manpower.Incident_FK, linked to Incident.Incident_PK
Manpower.Unit_ID
Manpower.Code
Manpower.Manpower_Record_Time
Manpower_1.Incident_FK, linked to Manpower.Incident_FK
Manpower_1.Unit_ID, linked to Manpower.Unit_ID
Manpower_1.Code
Manpower_1.Manpower_Record_Time
[/ul]
A second instance of Manpower is used to capture the second time stamp for the response interval measurement.
I group first by Event_Number and then by Unit_ID. I'm working now on turnout time, so for that I filter by the dispatch code from Manpower and the enroute code from Manpower_1.
Now, here is where the waters get muddied. There often are multiple time stamps with the same code but with different times (e.g., an ambulance mistakenly marks enroute twice), and the second and subsequent time stamps need to be excluded. So I have the following group-level summaries:
[ul]
Min of Manpower.Manpower_Record_Time
Min of Manpower_1.Manpower_Record_Time
[/ul]
To figure turnout time (in minutes and decimals) for individual events, I have this formula field named Turnout Time in the group footer for Unit_ID:
[ul]
datediff ("s",Minimum ({v_Manpower.Manpower_Record_Time}, {v_Manpower.Unit_ID}),Minimum ({v_Manpower_1.Manpower_Record_Time}, {v_Manpower.Unit_ID}))/60
[/ul]
It is this field from which I need to calculate the various summaries, but Crystal won't let me create a summary on that field.
I am a relative novice with Crystal, and I've struggled with various ways to work around this. I've tried it with a subreport and a shared variable -- my first venture into using variables. I've tried it with running totals instead of a group summary for the minimum values. It seems the sticking point is trying to summarize a formula field that is a calculation of another summary.
I am using CR Standard Version 10.0.5.1506. The database is SQL.
Can anyone help on a "See-Spot-Run" level? Thanks in advance!
It's similar in that I want a report-level average for various ambulance response intervals (turnout time, drive time, etc.), as well as the following report-level summaries: minimum, maximum, median, 90th percentile, and (3 * standard deviation) + average (to identify statistical outliers).
The data come from two tables named Incident and Manpower. The Incident table includes data about the overall event and the Manpower table includes individual time stamps for individual units (fire trucks, ambulances, etc). All time stamps from start to finish are logged in Manpower for every unit, along with individual codes to identify what each specific time stamp represents (unit dispatched, unit enroute, etc.).
The report includes these fields (among others):
[ul]
Incident.Event_Number
Incident.Incident_PK
Manpower.Incident_FK, linked to Incident.Incident_PK
Manpower.Unit_ID
Manpower.Code
Manpower.Manpower_Record_Time
Manpower_1.Incident_FK, linked to Manpower.Incident_FK
Manpower_1.Unit_ID, linked to Manpower.Unit_ID
Manpower_1.Code
Manpower_1.Manpower_Record_Time
[/ul]
A second instance of Manpower is used to capture the second time stamp for the response interval measurement.
I group first by Event_Number and then by Unit_ID. I'm working now on turnout time, so for that I filter by the dispatch code from Manpower and the enroute code from Manpower_1.
Now, here is where the waters get muddied. There often are multiple time stamps with the same code but with different times (e.g., an ambulance mistakenly marks enroute twice), and the second and subsequent time stamps need to be excluded. So I have the following group-level summaries:
[ul]
Min of Manpower.Manpower_Record_Time
Min of Manpower_1.Manpower_Record_Time
[/ul]
To figure turnout time (in minutes and decimals) for individual events, I have this formula field named Turnout Time in the group footer for Unit_ID:
[ul]
datediff ("s",Minimum ({v_Manpower.Manpower_Record_Time}, {v_Manpower.Unit_ID}),Minimum ({v_Manpower_1.Manpower_Record_Time}, {v_Manpower.Unit_ID}))/60
[/ul]
It is this field from which I need to calculate the various summaries, but Crystal won't let me create a summary on that field.
I am a relative novice with Crystal, and I've struggled with various ways to work around this. I've tried it with a subreport and a shared variable -- my first venture into using variables. I've tried it with running totals instead of a group summary for the minimum values. It seems the sticking point is trying to summarize a formula field that is a calculation of another summary.
I am using CR Standard Version 10.0.5.1506. The database is SQL.
Can anyone help on a "See-Spot-Run" level? Thanks in advance!