Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi guys,
So let's say I have a table that looks as follows:
has dog | has cat | has car |
---|---|---|
1 | 0 | 1 |
0 | 1 | 1 |
0 | 1 | 1 |
1 | 1 | 1 |
What I want to create is a bar chart that plot's the sum of each column as a bar, i.e. the number of people who have a dog, cat or car. However, in reality i have a table with hundereds of columns in the table, and 10000's of rows. What I tried using is crosstable, However, I end up with a table that has millions of lines, and the dashboards has to load almost a minute before I can use it.
Is there any more efficient way to do this?
Thanks for your help!
Cheers,
Daniel
How did you define your cross-table?
Did you end up with 3 or more columns?
How does your model look like?
if you got 100's of column and multiply that by 10000s rows you will end up with few million rows.
Feeling Qlikngry?
The cross table looks as follows:
ID, linked to rest of data | Variable | Value |
---|---|---|
1 | has car | 1 |
2 | has car | 1 |
3 | has car | 1 |
4 | has car | 1 |
1 | has dog | 1 |
2 | has dog | 0 |
3 | has dog | 0 |
4 | has dog | 1 |
1 | has cat | 0 |
2 | has cat | 1 |
3 | has cat | 1 |
4 | has cat | 1 |
The model consists of two tables, the first one that contains all data not used in the bar-charts, and the second one is the cross table defined above. The way I create the bar chart is through an if condition on the Variable field in the dimension. However, as mentioned it's too slow.
Another thing I've tried is, instead of using the crosstable, creating an empty fake-dimension in the bar chart, and adding all fields I want to display as measures. This works fine performance wise. However, I can only display the field names with a legend this way. What I want is an annotation below the bar.
Thaks for your help!
What will be the dimension for the bar chart?
Could you attached your app?