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

Chart showing only certain group records and totals others 1

Status
Not open for further replies.

crogers111

Technical User
Jan 23, 2004
158
US
CRXI
SQL

SAMPLE DATA

Patient Paid

Joe Doe 1500
Tom Doe 1800
Bill Doe 300
Jane Doe 700

Report is grouped by Patient with subtotals for amount paid.


There is a parameter for a Paid Threshold (?Threshold) which determines which patients show on the report based on the Sum{data.AmountPaid}, @Patient.

The report only shows patients that have a paid amount >= ?Threshold which is the easy part and I can do with either a Group Selection formula:

Sum ({Data.AmountPaid}, {@Patient}) >= {?Total Paid Threshold}

Or a Suppression Formula in the Patient Group Footer where the subtotals appear:

Sum ({Data.AmountPaid}, {@Patient}) < {?Total Paid Threshold}

PROBLEM:

I need to display a chart that shows a slice for each of those that have met the threshold with an ‘others’ section for the subtotal of PaidAmount the remaining records.

For Example..

If the parameter ?Threshold = 1000
Then my reports shows:

Tom Doe 1800
Joe Doe 1500

I need a chart that shows a slice for Tom at 1800, a slice for Joe at 1500 and then a slice for ‘others’ for the total 1000.

I'm aware of the 'Charting on Print-Time Formulas' document but really hoping there's an easier solution.
 
Create a formula:

if Sum ({Data.AmountPaid}, {@Patient}) >= {?Total Paid Threshold} then
{table.patient} else //or {@Patient}?
"Other"

Use this as your on change of field, and use sum of {data.amountpaid} as your summary field.

-LB

 
That did it !

I was close to this soultion but was trying with the following formula which obviously wasn't working and the correct formula you provided above just wasn't coming to me...


if Sum ({Data.AmountPaid}, {@Patient}) >= {?Total Paid Threshold} then Sum ({Data.AmountPaid}, {@Patient})


Thanks lbass, add another pink star to your stockpile !
 
crogers,
if you really mean this "Thanks lbass, add another pink star to your stockpile !"
then click on the "Thank lbass for this valuable post" link and give her the star that she most certainly does deserve.

lbass provides an incredible amount of help in these forums!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top