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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Summarizing Non-Summarizing Formula's

Status
Not open for further replies.

giggles7840

IS-IT--Management
Mar 8, 2002
219
US
Oracle 11g
CR 2008 SP5

I created a formula for my Detail line which is SumFormula: sum(field1) - sum(field2)

Now i need a subtotal of this number in the Group Footer and one in the report footer. I have been out of CR for a while and need a refresher on how I have done this in the past.

I can't sum the formula and I cant create a running total....I need to sum up the values that SumFormula spits out in the detail section placed in the GF and RF.

Any help is greatly appreciated!
 
Correction SumFormula: sum(field1, group field) - sum(field2, group field)
 
I was able to get my subtotal another way by creating two variables...

Subtotal:
whileprinitingrecords;
numbervar SubTotal:= SubTotal +{@Bonus w/o Exchange05}

Reset:
whileprinitingrecords;
numbervar SubTotal:=0

I am still struggling to get the Grand Total for the Report Footer.

Any Ideas?
 
For the Report Total, just create another variable that does the same thing as your "SubTotal" variable, but that does not get reset. Change your SubTotal Formula as follows:

Code:
whileprinitingrecords;
numbervar Total:= Total + {@Bonus w/o Exchange05};
numbervar SubTotal:= SubTotal +{@Bonus w/o Exchange05;

For the report Total, add a formula that returns the value of the "Total" variable, ie

Code:
whileprinitingrecords;
numbervar Total

Hope this helps.

Cheers
Pete
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top