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

Announcements
Join us in Bucharest on Sept 18th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
sunil_sawargave
Contributor III
Contributor III

Sum of different value of one column with codition

Hello all,

i am new on Qlik sense, 

sunil_sawargave_2-1664781117837.png

Here I want to Sum SCRAP COST value column with "Same Date", "Same Shop NAME", "Same REASON CODE"

pls revert me.

 

Thanks 

Sunil

 

 

 

Labels (2)
1 Solution

Accepted Solutions
sunil_sawargave
Contributor III
Contributor III
Author

Thanks For your valuable reply MayilVahanan,

Its Working Fine , Thank you very much.

 

Sum(Total<[SHOP NAME],  [REASON CODE] >  [SCRAP COST])

 

Thanks & regards

Sunil

View solution in original post

12 Replies
brunobertels
Master
Master

Hi 

May be this 

 

Aggr(sum([SCRAP COST ],Date,[SHOP NAME],[REASON CODE])

sunil_sawargave
Contributor III
Contributor III
Author

hi ,

thanks Brunobortels ,  for your advice but not working

 

Error in Expression: Aggregate takes at least two parameter.

 

 

brunobertels
Master
Master

Hi 

my bad 

try like this :

Aggr(sum([SCRAP COST ] ) ,"Date",[SHOP NAME],[REASON CODE])

and replace "Date" with your date field name 

regards 

MayilVahanan

Hi

Create a table chart and add, 

Dim: "Same Date", "Same Shop NAME", "Same REASON CODE"

measure: sum([SCRAP COST ])

are u facing any issue ?

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.
sunil_sawargave
Contributor III
Contributor III
Author

sunil_sawargave_0-1664791482494.png

Thanks  but it does  not display any value.

Thanks

 

sunil_sawargave
Contributor III
Contributor III
Author

Sum([SCRAP COST])

Working but

my requirement is Sum([SCRAP COST]) with Same [REASON CODE], Same[SHOP NAME]

Thanks

 

MayilVahanan

In that case, u can remove Date dimension.

If my understanding is wrong, can u explain ur requirement in details

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.
sunil_sawargave
Contributor III
Contributor III
Author

Ok thanks for revert me,

sunil_sawargave_0-1664793103227.png

 in the above table there is one filter pane Date for select,

In table Column Are "Cost Center", "SHOP NAME"", "SCRAP COST" ,& "REASON CODE"

I want to add SUM([SCRAP COST]) if [SHOP NAME] will same &  [REASON CODE] also same.

In Above Screen shot,

I Want to Add Sum[SCRAP COST] Whose Shop name=P BLOCk & Reason CODE=19,

Same like that in my table multiple Shop name & Multiple reason code so i want to Sum[SCRAP COST] whose Shope name will same & Reason code will be same.

I hope you will get my requirement .

 

Thanks

MayilVahanan

Hi

Try like below

Sum(Total<[SHOP NAME],  [REASON CODE] >  [SCRAP COST])

It will display total scrap cost based on shop name & reason code

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.