Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Displaying Minimum Value from SUM Total at bottom of the Report

Status
Not open for further replies.

lcutliffe

IS-IT--Management
Dec 1, 2006
30
US
Hi,
I have a crystal report that is supposed to show the shortest amount of time per job operation. I have all the {jobtran.a_hrs} totalled up into a sum called Sum_jobtran.a_hrs. I have it grouped by job operation so I have a total for each operation. NOW, I need to be able to display the lowest total of Sum_jobtran.a_hrs at the report footer but when I try to use the minimum value for Sum_jobtran.a_hrs, I get THIS FIELD CANNOT BE SUMMARIZED.
 
Create a formula like this and place it in the group section and suppress it:

whileprintingrecords;
numbervar min;
if groupnumber = 1 then
min := sum({jobtran.a_hrs},{table.joboperation}) else
if sum({jobtran.a_hrs},{table.joboperation}) < min then
min := sum({jobtran.a_hrs},{table.joboperation});

Then in the report footer, use this formula to display the result:

whileprintingrecords;
numbervar min;

-LB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top