Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
kaylaramsey2
Partner - Contributor III
Partner - Contributor III

Partial Sum not correct

Hello,

My partial sum is not correct.  See screenshot below...

My issue is with the Duplicates column.  If you add up 5+2+3 you get 10 but my partial sum says 13. 

I have also attached my code.  Any thoughts?

Capture.PNG

1 Solution

Accepted Solutions
pooja_prabhu_n
Creator III
Creator III

Hi,

Partial Sum is considering expression total.

hence Duplicate=Total Result-1

                          =14-1

                          =13

You are getting 13 as Duplicate partial sum.

If you are using Straight table you can change the expression total to sum of Rows.

In pivot table you can use below expression.

=Sum( Aggr( Sum(Result)-1,LabNM))

Labname.PNG

Please find the attached qvw file for your reference

Thanks,

Pooja

View solution in original post

6 Replies
vamsee
Specialist
Specialist

Hey Kayla, your attachment is missing. Can you please reattach your QVW

kaylaramsey2
Partner - Contributor III
Partner - Contributor III
Author

I can only provide you with the expression code.  I can not share client data.

Frank_Hartmann
Master II
Master II

can u share a pic of the full expanded table?

kaylaramsey2
Partner - Contributor III
Partner - Contributor III
Author

I am only looking at one patient here.  The fully expanded view would just show you the one patientID for each LabNM.  The Result column is just a count of a specific flag.  The partial sum the Result column shows is the correct number.  My issue is with the Duplicates partial sum

Frank_Hartmann
Master II
Master II

can you scramble the sensitive data and upload the qvw?

for scrambling go to settings --> document settings --> scrambling and choose the fields with sensitive data to

scramble. then save the document and upload the qvw!

pooja_prabhu_n
Creator III
Creator III

Hi,

Partial Sum is considering expression total.

hence Duplicate=Total Result-1

                          =14-1

                          =13

You are getting 13 as Duplicate partial sum.

If you are using Straight table you can change the expression total to sum of Rows.

In pivot table you can use below expression.

=Sum( Aggr( Sum(Result)-1,LabNM))

Labname.PNG

Please find the attached qvw file for your reference

Thanks,

Pooja