Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello Everyone,
I have created a pivot table then I dragged and dropped the second attribute in order ro create a matrix, but it doesn't show me all my the rows in my database only if I select a filter as you can see in the screenshots. Please help me resolve this problem.
Thank you for you Help.
What is your pivot table measure expression?
Does my problem come from this ?
Maybe your selection is limiting to 1 "nom_niveau_couleur" and without selection there is many values so only() function is returning null. Sorry i don't understand fully with details and language. but that's reasonable to think. What if you do count(nom_niveau_couleur) instead and show as number (or a 2nd expression). Does this equal 1 where you expect it to?
Yes, It worked but now it doesn't show me the colours .
Did you change "Representation" to text? I realized it was going to drop out the colours, I wanted to see what the count number it would return. if it's more then 1 your only function would not work.
Here is the result
So you have cells with > 1 color (seen now with your count(nom_niveau_couleur)). You'll need to determine which color should be displayed in this scenario. For example BETREMIEUX x C#. Maybe its a max date you need to limit color by, or have a numeric colour equivalent and take max colour. Or maybe your colour association doesn't match your pivot table when you thought it does.
But if you use only() and on a measure that has more then 1 value it will return null. I believe this is your issue.
So how can I get this right so It does show me the highest level or the highest colour ?
How do you want to determine "highest level". Let's say you have below where you want the colour_value used to determine which color to take (highest colour_value) in case of a tie
load * inline [
colour, colour_value
red, 10
blue, 9
green, 8
]
;
Try this calculation:
firstsortedvalue([colour], aggr(max(colour_value), [Nom_Complet], [Com_Technologie]))