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: 
Not applicable

Sum of revenue per customer per year with condition

Dear all,

I have the following issue:  I am trying to get a sum of revenue per customer per year, but only for years that the customer has exceeded a predetermined sum of of revenue for that year.

eg:

aa 2015 100

bb 2013 50

cc 2015 110

aa 2015 80

bb 2014 40

cc 2015 90

bb 2014 70

show customer data only when yearly sum over 100

result WITHOUT the condition

aa 2015 180

bb 2013 50

bb 2014 110

cc 2015 200

result WITH the condition

aa 2015 180

bb 2014 110

cc 2015 200

So far I am unable to solve it.  Any ideas?

Thank you

5 Replies
Anil_Babu_Samineni

May be this? Attached the qvw

Capture.PNG

Please add me Anil_Babu_Samineni to interact faster when reply back. Speak low think High.

Before develop something, think If placed (The Right information | To the right people | At the Right time | In the Right place | With the Right context)
Kushal_Chawda

Data:

LOAD *,

          rowno() as Row

FROM Data

Create straight table

Dimension:

Category

Year

Expression:

1) Without condition

=sum(Revenue)

2) With condition

=sum({<Row={"=sum(Revenue)>100"}>}Revenue)

antoniotiman
Master III
Master III

HI,

DIm : ID,Year

without condition Expr :

Sum(Value)

with condition

If(Sum(TOTAL <ID,Year> Value) > 100,Sum(Value))


egards,

Antonio

zebhashmi
Specialist
Specialist

try this

If (Sum(A)>100,sum(A))

zebhashmi
Specialist
Specialist

can you share the condition please