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

Showing Summary Values in multiple places

Status
Not open for further replies.

mholbert

IS-IT--Management
Jan 10, 2006
105
US
I have created a report in v9 to show Payments, Adjustments, and Charges for Doctors. The report groups by Doctor, Type(payments, adjustments, charges), and Department. Each group has its own totals for Month-To-Date, Year-To-Date, and Prior-Year-To-Date. My problem is that I need to show the total payments, adjustments, and charges at the end of each doctor as well as at the end of the group.

Thoughts?

MHolbert
 
It depends on how you created the summaries. If you inserted them, you can insert them again and choose additional group levels and/or a grand total.

If you used running totals, then you would need to add additional running totals that reset at the doctor level or reset never (for the grand total).

If you used variables, you would need to add reset formulas, accumulation, and display formulas for a new variable at each group level.

-LB
 
I inserted the summaries. Basically, I am receiving data from a stored procedure against a sql 2k db. Because the data is delivered for a particular 'period' and because I am representing MTD, YTD, and Prior YTD values, I chose to use the following formulas to have the data populated in the appropriate column of the detail line.

MTD Formula

If Left ({?@Begindate},6)= {cusSpRevProd;1.period}
Then {cusSpRevProd;1.nMtdAmt}
Else 0.00

YTD Formula

If Left({?@Begindate},4)= Left({cusSpRevProd;1.period},4)
Then {cusSpRevProd;1.nMtdAmt}
Else 0.00

Prior YTD Formula

If Left({?@Begindate},4)<> Left({cusSpRevProd;1.period},4)
Then {cusSpRevProd;1.nMtdAmt}
Else 0.00

'Period' is returned as YYYYMM.

I am suppressing the detail lines and only showing the summaries at the type (payments, adjustments, charges), department, and Provider levels. The problem is, the sp returns the data with a summ_desc value attached. That value is either 'payments', 'adjustments', or in the case of charges the names of the various departments that charges get grouped into, for example, 'radiology', 'ecg', 'laboratory', etc.

The groupings and summaries all work perfectly, except that I need to show the total payments, adjustments, and charges again at the end of the provider, and when I try to reinsert the summary at the provider level, it shows the same value as the summary already there.

The only way I know to accomplish this is by inserting a subreport, and only showing the final totals.

I hope the above is not too terribly convoluded.

Thanks in advance for the advice. MH
 
You are not consistently referring to your groups in order, so can you please explain what is Group#1, Group#2, Group#3?

It sounds like you want a summary of inner group results again in a higher order group footer. Ordinarily you could insert a crosstab, but with your manual crosstab already, I would try using running totals. For example, insert a running total on {@MTDformula}, sum, evaluate using a formula:

{table.type} = "Payment"

Reset on change of provider. Repeat for the other two payment types, changing the evaluation formula accordingly. Place the running totals in the provider group footer.

-LB
 
Interesting, I am embarrassed to say this is the first time I have ever used Running Totals. Works like a dream. Thanks. MH
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top