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

Running Totals

Status
Not open for further replies.

FluffyKitty

Instructor
Jul 8, 2002
8
US
Currently, I have created a RUNNING TOTAL that returns the total in (currency format) per GROUP. My goal is to add a new field in the REPORT FOOTER that will display the 'GRAND TOTAL' (an accumulation of the running totals).

However, when I try to sum the running total it gives me the following error message: "The summary/running total field could not be created"

Can anyone help me? Is it even possible to put a sum field as a GRAND TOTAL when it's based on a running total?

Thank you so much in advance.
 
You may not have needed a Running Total at all, it's hard to say without more info.

You can create another Running Total identical to the one you have except that you'd select NEVER in the Reset area, then place it in the report footer.

If you place any field on the details of a report, you can right click it and select Insert Summary-><choose the type of aggregate function>, and select to Insert Summary Fields for All Groups and Insert Grand Total.

Then you can delete the field that you used to perform the summaries on if need be.

-k
 
wow! nice response time :)

here's what I have...

These 2 calculated fields are located in the group footer which is USER_NAME...

[TOTAL MINUTES]
NumberVar TotalSec := datediff(&quot;s&quot;, minimum({qry_Efficenies.STATUS_DT},{qry_Efficenies.USER_NAME}), maximum({qry_Efficenies.STATUS_DT},{qry_Efficenies.USER_NAME})) ;
NumberVar Hours := Truncate (Remainder ( TotalSec,86400) / 3600)*60;
NumberVar Minutes := Truncate (Remainder ( TotalSec,3600) / 60);
Hours + Minutes

[TOTAL COST]
${@Minutes_nbr}*1.49

When I attempt to create a field sum(TOTAL_COST) I get that error message. All calculations work &quot;perfectly&quot; as long as I keep them in the group footer.

Thhhhhaaaank Yoooouuuuu!
 
because this formula uses minimum and maximum, you will have to use a running total written with variables. See faq149-182 for the technique. Ken Hamady, On-site Custom Crystal Reports Training & Consulting
Public classes and individual training.
Expert's Guide to Formulas / Guide to Crystal in VB
- tek@kenhamady.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top