Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I have a table of 2 columns, say, A and B.
Each column has numbers from 1 to 10
For each of these numbers I want to find out, if this number is present more often in column A or in column B
In Excel I could do this as the difference of CountIFs (on the picture). The chart shows a bar of height 1 at position 10, because number 10 is found 2 times in column A and 1 time in column B
Help me, please, how can achieve the save in QlikSense?
Hello Airapport,
It is easier if you can modify data model. First, you have to unpivot the tabular data.
SampleHorizontal:
LOAD floor(rand()*10)+1 as A, floor(rand()*10)+1 as B AutoGenerate 20;
SampleVertical:
NoConcatenate
LOAD A as Value, 'A' as Column Resident SampleHorizontal;
LOAD B as Value, 'B' as Column Resident SampleHorizontal;
Drop Table SampleHorizontal;
Then you can use "Value" as dimension and "Count({<Column={"A"}>} Value) - Count({<Column={"B"}>} Value)" as measure in your bar chart.
I hope it solves.