Forum Discussion
Get correct % per individual
Hope someone can fix what I'm getting wrong. I need a table that summarises % of records with a certain value for each person that created records. I can get this into a simple yes/no substitution (if value = X then yes, else no) and that into a table. But as soon as I try to represent these values as a % for each row, it looks like the second table in my screenshot - its blank.
I've created these measures in an attempt to get this to work. I suspect there's something really simple in one or more measures, but I can't see it.
FTF In = CALCULATE(COUNTA(Tablea[FTF Count]),FILTER(Tablea,Tablea[FTF Count] = "Yes"))
Total FTF = CALCULATE(COUNTA(Tablea[FTF Count]),ALLEXCEPT(Tablea,Tablea[Submitter]) )
FTF % = [FTF In]/[Total FTF]
ARRGGHHH! Found the issue was in the data, not the measure. Data had " around it and wasn;t pattern matchign correctly. Sorry for the waste of time.
4 Replies
- Greg_DecklerCommunity Champion
Can you use a Quick Measure or Show As Percent of Grand Total?
- shill1000Helper IV
No, it needs to be summaised by agent and overall, hence the first table. I think I've made a fundamental mistake in my measures, but I can't see how to fix it. If I explain it like this, maybe it will make more sense:
I need to both count and measure (as a percentage) how many records per submitter are flagged as FTF. It's a text value in the base data, so I set up the query to add a column counting where the value is FTF as a 'Yes' and all others as 'No'.
The idea being I would count the # of 'Yes' values against the total (by submitter and overall). You can see the counts work correctly in the first table.
But to get the %, logically I set up what I thought were correct measures to get the count of 'Yes' values then divide these by the overall total to get the % measure. I know I've got somethign wrong, I just can't see what it is.
I really need to get to grips with DAX properly. :(
- shill1000Helper IV
I've narrowed it down to the FTF In measure. This is returning 0 results. but I can't see what's wrong with the function, and there appears nothing wrong with the syntax?