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

Announcements
Congratulations to the new Qlik Luminary and Partner Ambassador class! Meet them here
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Set analysis in text object

Hi

i need to show the sum of the amount for the selected period which are positive group by branches in text object.

For Ex, I have the data like

Month     Branch     Amt

Jan      A               10

Feb     A               -20

Mar     A               20

Jan      B               -10

Feb     B               20

Mar     B               40

    I need to show in text object, the value for the selected period jan is sum(Amt)= 10.(only A is having Positive values)

for feb, sum(amt) is 10 (bcoz only B is having sum(amt) as positive)

for Jan,Feb is 10 (bcoz only B is having sum(amt) is positive A is givining neg value(-10) dont consider)

for jan,feb,mar is 60 bcoz sum(amt) for A (10)and B (50) is Positive.

Hope someone can help me out,

thanks in advance.

Labels (1)
5 Replies
CELAMBARASAN
Partner - Champion
Partner - Champion

Hi,

     Try this

     Sum(Aggr(If([Amt]>=0,[Amt]),[Amt]))

Hope it helps

Celambarasan

CELAMBARASAN
Partner - Champion
Partner - Champion

Hi,

     Try this

     Sum(Aggr(If(Sum(Amt)>=0,Sum(Amt)),Month,Branch,Amt))

Hope it helps

Celambarasan

jagan
Partner - Champion III
Partner - Champion III

Hi,

Try this

=Sum(Aggr(If(Sum(Amt) > 0, Sum(Amt)),Branch, Month))

Hope this helps you.

Regards,

Jagan.

Not applicable
Author

Hi

thanks for reply...

But its not working...

could anyone help me....

thanks in advance....

kaushiknsolanki
MVP
MVP

HI,

     Try this expression in text box.

     =sum({<Branch = {'=sum(Amt)>0'}>}Amt)

Regards,

Kaushik Solanki   

Please remember to hit the 'Like' button and for helpful answers and resolutions, click on the 'Accept As Solution' button. Cheers!