Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us in Zurich on Sept 24th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
upaliwije
Creator II
Creator II

partial sum

Hi,

I have a pivot table in my data table and output report is as follows

BRANCHITEMSUM(QTY)SUM(UNIT_PRICE)(QTY)*(UNIT_PRICE)
ABCCard Printers=1650001165,000165,000
ABCCPU=81000190,00090,000
ABCDot Matrix Printers=75000075,0000
ABCHigh End Scan Kodak=1280000128,0000
ABCHP 401 Printers=45000145,00045,000
ABCScanners G3110=19000119,00019,000
ABCTFT Panels=13000113,00013,000
ABCUPS (3.0kva)=1200000120,0000
ABCUPS (650VA)=500015,0005,000
ABCTotal6660,000-

Here I do not get total in last column (qty)*unit_price) .Pls advise me where I have gone wrong

1 Solution

Accepted Solutions
jonathandienst
Partner - Champion III
Partner - Champion III

You should not be using 'naked' fields* - for the last column you need:

     Sum(QTY * UNIT_PRICE)

* fields not wrapped by one or other aggregation function (like Sum(), Max(), Count()...)

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein

View solution in original post

2 Replies
jonathandienst
Partner - Champion III
Partner - Champion III

You should not be using 'naked' fields* - for the last column you need:

     Sum(QTY * UNIT_PRICE)

* fields not wrapped by one or other aggregation function (like Sum(), Max(), Count()...)

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
sunny_talwar

Working sample from your data using the expression provided by jonathan

Capture.PNG