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

Announcements
Want to see what's currently in public preview? We've pulled it all together in one place. Check it out here
cancel
Showing results for 
Search instead for 
Did you mean: 
GraceGao
Creator
Creator

Set analysis expression

Hi Experts,

i would like to calculate amount as below ,however, no result. Can it be realized? Please help. 

sum({condition A} Quantity *avg({condition B} price))

I want to Quantity * avg (price) and get sum amount.  if i write as below the result is not expected.

sum({condition A } Quantity)*avg({condition B})

2 Replies
lorenzoconforti
Specialist II
Specialist II

Try this

 

sum({condition A} Quantity * $(=avg({condition B} price))  )

dplr-rn
Partner - Master III
Partner - Master III

agree with lorenzo.

i would put the avg expression in a variable  so that its calculated globally