Skip to main content
Announcements
Introducing Qlik Answers: A plug-and-play, Generative AI powered RAG solution. READ ALL ABOUT IT!
cancel
Showing results for 
Search instead for 
Did you mean: 
proctors
Creator
Creator

Divide Total Row

I need to take the Sum of one total and divide it by the other, but it ends up blank. I need 412.8 / 146.25 = 2.82

Expression for weighted is: Sum(Total [Sum wRVU in FY for each code])/SUM( Total [Adjustment if CPT Not Hourly])

CPT Code # of units billed in FY Adjustment if CPT Not Hourly wRVU Sum wRVU in FY for each code Weighted average wRVU per unit billed
9079144.003.0012.0 
9083231.501.504.5 
9083453.752.0010.0 
9083720.403.006.0 
9615023635.400.50118.0 
9615113119.650.4862.9 
9615229544.250.46135.7 
9615412118.150.4554.5 
96155213.150.449.2 
NOCHG1616.000.000.0 
Total 834 146.25 11.83 412.8 0.00
1 Solution

Accepted Solutions
sunny_talwar

May be this

Round(Sum(Aggr(Sum([Charge Qty])*(Sum([RVU WORK])/Sum([Charge Qty])), [CPT Code])), 0.1)/

Round(Sum(Aggr(IF([CPT Code]='90837', (Sum([Charge Qty]*0.2)),

IF([CPT Code]='90832', (Sum([Charge Qty]*0.5)),

IF([CPT Code]='90834', (Sum([Charge Qty]*0.75)),

IF([CPT Code]='96150', (Sum([Charge Qty]*0.15)),

IF([CPT Code]='96151', (Sum([Charge Qty]*0.15)),

IF([CPT Code]='96152', (Sum([Charge Qty]*0.15)),

IF([CPT Code]='96153', (Sum([Charge Qty]*0.15)),

IF([CPT Code]='96154', (Sum([Charge Qty]*0.15)),

IF([CPT Code]='96155', (Sum([Charge Qty]*0.15)), Sum([Charge Qty])))))))))), [CPT Code])), 0.01)

View solution in original post

12 Replies
Anil_Babu_Samineni

What formula used for?

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
Siva_Sankar
Master II
Master II

Use the expression to get your expected output sum([Sum wRVU in FY for each code])/sum([Adjustment if CPT Not Hourly]).

I got your expected answer, refer the screenshot and attached qlikview file.

color.JPG

shiveshsingh
Master
Master

Hi

PFA

shiveshsingh
Master
Master

proctors
Creator
Creator
Author

I'm getting a bad field name error. I'll post the file. (repost with SA off)

proctors
Creator
Creator
Author

Still getting different number. See file I attached to my earlier post.

sunny_talwar

Please remove the section access from the attached file.

proctors
Creator
Creator
Author

Sorry, just reposted above.

sunny_talwar

May be this

Round(Sum(Aggr(Sum([Charge Qty])*(Sum([RVU WORK])/Sum([Charge Qty])), [CPT Code])), 0.1)/

Round(Sum(Aggr(IF([CPT Code]='90837', (Sum([Charge Qty]*0.2)),

IF([CPT Code]='90832', (Sum([Charge Qty]*0.5)),

IF([CPT Code]='90834', (Sum([Charge Qty]*0.75)),

IF([CPT Code]='96150', (Sum([Charge Qty]*0.15)),

IF([CPT Code]='96151', (Sum([Charge Qty]*0.15)),

IF([CPT Code]='96152', (Sum([Charge Qty]*0.15)),

IF([CPT Code]='96153', (Sum([Charge Qty]*0.15)),

IF([CPT Code]='96154', (Sum([Charge Qty]*0.15)),

IF([CPT Code]='96155', (Sum([Charge Qty]*0.15)), Sum([Charge Qty])))))))))), [CPT Code])), 0.01)