Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
lucastro_123
Contributor III
Contributor III

Question about SUMIF in QLIKView

Hello guys!!

 

    I'm new at QLIK View and i'm having difficulty to sum a quantity with conditions. Here's the thing:

QLIK_Question.png

 

I need to Sum all the collumn "Day to Day * Real" and divide that for the sum of the Real collumn. All that aggregate by the "Ano" collumns, the "Mês" column and the B and C collumn there in blank. All of that to appear in another collumn next to it. That would be (done in Excel):

 

QLIK Question2.png

 

I tried the 

Sum(Aggr([Day to Day * Real],Ano,Mês,B,C)) 

 

With no luck... It's just returns 0s...

Can anyone help me? 

Thanks a lot!!!

Labels (5)
14 Replies
lucastro_123
Contributor III
Contributor III
Author

it gets back "0" too...

sunny_talwar

Are these the fields in your dashboard?

Year
Month
Country
[Day to Day]
[Real]

 

Also, Year Month and Country are your dimensions in the chart?

lucastro_123
Contributor III
Contributor III
Author

Year = Dimension at the script
Month = Dimension at the script

Country = Dimension at the script
[Day to Day] = Expression in the chart
[Real] = Expression in the chart

The dimensions in the chart are: Year, Month, Column B(Information about the country, also from the script) and Country

The expressions are Programed, Real, Day to Day and "Day to Day * Real"

sunny_talwar

What are the expressions behind [Day to Day] and [Real]? Is it something like Sum([Day to Day]) or something?

lucastro_123
Contributor III
Contributor III
Author

Sorry for the late reply my friend. 

Yes, it was a calculated dimension, but i was able to solve my problem using aggregate.

I used Aggr on all the sum( "day to day" x "real")

and then divided that aggr for the aggr  sum("real")

Using year, month and country for the dimensions in the aggr.

Thanks for all the replies and will have another problem in my next post that is a challenge one!