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

Can you take the max. value of running total & use in previous group?

Status
Not open for further replies.

cf53bank

Technical User
Apr 6, 2005
3
US
I am using Crystal 8.5 - in a report I have group 1 = location and group 2 = category. All details are displayed in the group footers. The design is a follows

Group Footer 2 - Category
{TPV_COURSES.CATEGORY} {#training Units}

Group Footer 1 - Location
{#training Units by Location}

Example of data is a follows:
CATEGORY Training Units
Customer Service 50
Sales 30
Quality 30

Total 110

Next to the training units column I need to add a column for percent of learning. So for example when calculating the percentage of learning for 'Customer Service' the formula would need to take 50/110 to come up with 45%. But when I pull the {#training Units by Location} running total into group footer 2 instead of using the 110 value in the formula it uses '50' for Customer Service, '80' for Sales and '110' for Quality.

Is there a way to capture the maximum value of the {#training Units by Location} running total field and use it in a previous group?

Thanks in advance for your assistance.
 
Can you explain why you are using running totals? Are you only counting some records? If so, what is the condition you are using?

If you are able to instead use inserted summaries, you won't run into this problem. Even if you are using some condition, you might be able to work that into a conditional formula, as in {@somerecords}:

if {table.field} = "X" then {table.amt}

...on which you can then insert a summary. You could then easily use a formula like the following to get the percentage:

sum({@somerecords},{table.category}) % sum({@somerecords},{table.location})

-LB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top