Skip to Content
avatar image
Former Member

How to have Report Grand Total add up the values of a group summary field containing a formula

I am using a formula at the group level to display a total based on varyingcriteria.  In some instances, it will pull an average number and in others, it will sum up other summary fields in the group.  Therefore, it does not make sense to sum the orgiginal detail field in the grand total.  I need to take all the results from my formula summary field and add them up in the report total.

Is there a way to do this?  I have seen postings about putting formulas in the report header and then iin report footer about 'WhilePrintingRecords'  But not sure I understand the steps involved.  Please help with some specific detail.

The formula in my group field that I need to total at the report level:

if {@NBVerify} = TRUE then (Sum ({@Benchmark NB}, {@fullname}))*(({?End Date}-{?Start Date})/({?Average Calc}*30)) else Sum ({@Scheduled Count}, {@fullname})+Sum ({@Open Count}, {@fullname})+Sum ({@Hold Count}, {@fullname})

Thanks for any help.

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • Oct 15, 2015 at 02:39 PM

    Hi John,

    Modify the formula to:

    whileprintingrecords;

    numbervar subt := if {@NBVerify} = TRUE then (Sum ({@Benchmark NB}, {@fullname}))*(({?End Date}-{?Start Date})/({?Average Calc}*30)) else Sum ({@Scheduled Count}, {@fullname})+Sum ({@Open Count}, {@fullname})+Sum ({@Hold Count}, {@fullname});

    numbervar gtotal := gtotal + subt;

    subt;

    Create another formula with this code and place this on the Report Footer:

    whileprintingrecords;

    numbervar gtotal;


    -Abhilash

    Add comment
    10|10000 characters needed characters exceeded