Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

how to variable name to Diffrence

Hi Friends,

I crated Pviot table with values Sum(A) adn Sum(B). I want to take diffrence between these two values.

I created a varibale vDiff=Sum(A)-Sum(B). Its giving me a total aggregation difference.

.

Please let me know how to only difference between Sum(A) and Sum(B) specific to that row only.

Thanks

12 Replies
manideep78
Partner - Specialist
Partner - Specialist

Hi

Take A and B as Dimensions.

Now add an expression RangeSum(A)-RangeSum(B)

Hope this helps.

Regards,
Manideep

Not applicable
Author

Hi,

Add one more expression in pivot table with Expression label1-Expression label 2.

which will be nothing but Sum(A) -Sum(B) specific to that row only.

senpradip007
Specialist III
Specialist III

Give names for Sum(A) and Sum(B), for example let say you give Sum(A) as colA and colB for Sum(B). Now you can write colA - colB and you will get your desire result.

Not applicable
Author

RangeSum will work.

Please see if that helps.

Thanks!

ashfaq_haseeb
Champion III
Champion III

Hi.

write third expression as 

Sum(A)-Sum(B)

or

Column(1)-column(2)


Regards

ASHFAQ

anbu1984
Master III
Master III

You can use labels assigned to Sum(A) and Sum(B). Check this

Not applicable
Author

Please send the code I am working on Personal Edition

Not applicable
Author

Thanks Freinds

But I want to assign a varibale to Sum(A)-Sum(B).

Thanks

Pavan

anbu1984
Master III
Master III

Do you want to store difference for any particular row in the variable? What is the condition to select that row?