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

Group Total Help

Status
Not open for further replies.

Garyjr123

MIS
Sep 14, 2010
139
US
I have a report that I am having a hard time getting a grand total for a GH1 (using CR 9). The report is setup as follows.

GH1 SF.SRCFAC
GH2 TEST.TESTCODE [suppressed]
D [suppressed]
GF2a [TEST.NAME] [TEST.TESTCODE] Total Resulted: @Total Code

@Total Code: {#Other Code Total} + {#Stat Code Total} + {#Routine Code Total}

GF2b @Routine Code #Routine Total Code
GF2c '{TEST.TESTCODE}TIMED' #Other Code Total
GF2d @Stat Code #Stat Code Total
GF1 @Source Facility Total

@Source Facility Total: {#Other Code Total} + {#Stat Code Total} + {#Routine Code Total} (I know this is no where correct)

I want GF1 to have a grand total of [Total Resulted: @Total Code] from GF2a.
 
GaryJr123,

The most simple approach is to increment a second set of variables in each of your current running totals (one for each group, within the same RT Formula) to be used at the other group level. This will allow different reset patterns, etc. and often allows the most control.

For specific assistance, please provide your current Running Totals.

Hope this helps! Cheers!

Mike
---------------------------------------------------------------
"To be alive is to revel in the moments, in the sunrise and the sunset, in the sudden and brief episodes of love and adventure,
in the hours of companionship. It is, most of all, to never be paralyzed by your fears of a future that no one can foretell."
 
Thanks MC...here are the running totals for the report to get some more specific assistance.

GF2b #Routine Code Total:
Summary
Field to summarize: PATIENT.PID
Type of summary: distinct count
Evaluate
Use a formula: {TESTREQ.PLKEY} = '151'
Reset
On change of group: Group #2 TEST.TESTCODE -A

GF2c #Other Code Total:
Summary
Field to Summarize: PATIENT.PID
Type of summary: distinct count
Evaluate
Use a formula: {TESTREQ.PLKEY} = '164'
Reset
On change of group: Group #2 TEST>TESTCODE -A

GF2d #Stat Code Total:
Summary
Field to summarize: PATIENT.PID
Type of summary: distinct count
Evaluate
Use a formula: {TESTREQ.PLKEY} = '163'
Reset
Oon change of group: Group #2 TEST.TESTCODE -A

Let me know if there is more info you need.
 
Hey Gary,

Sorry for the delayed reply. In seeing this information, you have two options available. I assumed you had written your own Running Totals using formula fields (I assume the above is from the RT wizard? I have always writting my own).

I'd suggest creating a second set of three RT's, with the same criteria as above, only the reset would be Group #1. If this isn't returning the expected results, please advise and I can help you develop the formula method.

Cheers!

Mike
---------------------------------------------------------------
"To be alive is to revel in the moments, in the sunrise and the sunset, in the sudden and brief episodes of love and adventure,
in the hours of companionship. It is, most of all, to never be paralyzed by your fears of a future that no one can foretell."
 
MC,

Not a problem, thanks again for your help.

For the new set of RTs, are they placed in the GF2 and suppressed then I write a formula for the Source Facility (GH1) total? Can you give me a more specific example of how you want me to add this to the report?

Thanks,

Gary
 
Gary,

Yes, what you have described sounds correct - you are more or less mirroring the existing Running Totals, with the exception that all references to Group 2 would now be Group 1.

Yes, you will need a formula to place in GF2 to add these three new Running Totals together.

In the event this approach doesn't provide the intended results, please advise if the following is true and I can provide the alternative solution.
{#Routine Code Total} -- Count the occurances of Code 151
{#Other Code Total} -- Count the occurances of Code 164
{#Stat Code Total} -- Count the occurances of Code 163

Thanks Gary, please let us know should you have any further questions. [smile]

Mike
---------------------------------------------------------------
"To be alive is to revel in the moments, in the sunrise and the sunset, in the sudden and brief episodes of love and adventure,
in the hours of companionship. It is, most of all, to never be paralyzed by your fears of a future that no one can foretell."
 
MC,

I'm still not seeing the results that I need to. I inserted 3 GF2 and added the mirrored RT to the report (and suppressed them) with the group change with in the RT expert.

I added a formula to the GF1 where I added all the mirrored RT togther. No dice...

Thoughts?
 
Hi Gary,

I am thinking likely due to the structure of the report and nature of the summary involved that we need to take the formula approach -- can you please confirm my assumptions on the purpose of your original running totals, or advise in simple English the intent of each and I can provide you with the formula's.

Having never seen the RT's described as above, I would just like to be sure I am understanding the intent prior to starting writing the formulas themselves.

Thanks for your patience Gary, we'll get this resolved in the next post or two. [smile]

Cheers!

Mike
---------------------------------------------------------------
"To be alive is to revel in the moments, in the sunrise and the sunset, in the sudden and brief episodes of love and adventure,
in the hours of companionship. It is, most of all, to never be paralyzed by your fears of a future that no one can foretell."
 
MC,

Love to...

The report shows totals for # of tests run in GF2a (GH2: TEST.TESTCODEs). Each test has a priority associated with it (Routine, Stat, Timed/Other) and is broken out in the report showing totals for each priority for each test. Each test is run in a Source Facility (Endo, Cardiac, ICU etc) which is GH1 and I would like to see a total number of tests for each source facility.

So the report would look like this:

GH1 ED SOURCE FACILITY TOTAL: 14
GH2 TEST.TESTCODE [suppressed]
D [suppressed]
GF2a COMPLETE BLOOD COUNT CBC TOTAL RESULTED: 4
GF2b CBC ROUTINE: 1
GF2c CBC STAT: 3
GF2d CBC TIMED: 0

GF2a ALBUMIN ALB TOTAL RESULTED: 10
GF2b ALB ROUTINE: 5
GF2c ALB STAT: 4
GF2d ALB TIMED: 1

So five calculations for totals in this report. 3 for routine, stat, timed; 1 total for the test (routine + stat + timed/other = total tests resulted); and grand total for the source facility (test + test + test... = grand total for sourc facility).

Let me know if this helps.

Gary
 
MC,

We seemed to have lost touch here. I was wondering if you were able to look at my last post and determine how we are supposed to proceed with getting these totals to show up correctly.

Thanks,

Gary
 
MC,

Where did you go on me?

If MC doesn't answer can anyone else help me with this thread?

Thank you,

Gary
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top