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!

Bar Chart to Display Percentage

Status
Not open for further replies.

reporter2007

Technical User
Dec 21, 2009
8
US
I'm having trouble understanding how to get Crystal Reports 11 to display a percentage chart. I could do this 10 different ways with my eyes closed in Excel but CR is giving me a fit.

Essentially it is a count of records meeting a condition divided by the total count. Need single bar for each month representing percentage of total.

Thanks for your help
 
When you insert the sum on your conditional formula, in the same summary expert, check "show as percentage of"->Grand Total.

-LB
 
I tried and the graph showed the data in the "returned" column below.

I put the date field under "On change of"
Under show values I added my data field as sum and selected Percentage of sum.

The data consists of 1's or 0's
So on month 9 has 24 items with 16 1's...should return 67 but returned 19...i have no idea where it is getting 19 from.
mo Data Sum Pcnt Returned
9 24 16 67 19
10 27 19 70 22
11 18 17 94 20
12 34 33 97 39

Thanks for you help
 
What is the formula you are summing? Did you set the date to change on month using the Order button?

-LB
 
To answer your 2nd question..yes.

Your first question...

The data is derived from call-center tracking.
There is a created_dttm field and a closed_dttm field. The objective is to report the percentage of casses closed in 2 days. My formula named ClosedInTwo:

/////////////////////////////
datevar dt;
numbervar ct;
if

{CASE_DETAIL.CASE_STATUS_CODE}=1 //case open
then
dt := today()
else
dt := cdate({CASE_DETAIL.CLOSED_DTTM});

if dt-{CASE_DETAIL.CREATED_DTTM} <=2 then
ct :=1
else
ct :=0;
ct
////////////////////////////

on change of = created_dttm
Show value(s) = Percentage of Sum of @ClosedInTwo

Regards,
mw
 
Now I see--you're not looking for a percentage of the grand total, but instead the percentage of the monthly total. Create a formula like this:

sum({@ClosedInTwo},{table.date},"monthly")%count({table.recurringfield},{table.date},"monthly")

Then chart this formula.

-LB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top