Forum Discussion
Anonymous
6 years agoNot applicable
DAX Switch True
DAX experts, Here is how my data is set up: ID: Reason 1 Reason 2 Reason 3 Reason 4 1 Correct Incorrect Incorrect Correct 2 ...
- 6 years ago
So, with the structure of your data you can only get something like this :
Otherwise you need to transform your data, for that u need to use SQL,
here i'm ganna start by creating my table Check :
Then i can tranform it also with Sql :
So finaly i can get what i need on Power BI :
Rahal
6 years agoFrequent Visitor
Hi, if i understand what you want to do, you will need to create 4 measure for each reason and name them what you want :
Ofc replace ; with ,
Reason (1) = VAR R1=CALCULATE(count(Check[Reason 1]);Check[Reason 1]="Incorrect") RETURN if(ISBLANK(R1)=TRUE();0;R1)
- Anonymous6 years agoNot applicable
That is super helpful thank you!
When I go to make it into a clustered bar chart the axis is blank. How would I create a field to put in the axis so it labels all the bars as what the reason is?