Forum Discussion
Apply SUM Total to a Conditionally Formatted Column
- 1 year agoTest Sum =var s = SUMX(ADDCOLUMNS('Table',"s",if([APType]="Classic",0,VALUE([TEST]))),[s])RETURN if(s=0,"N/A",FORMAT(s,"#"))
Hi lbendlin - Thank you for the note, I did not notice that the images were too small when I was creating it. Apologies for that.
I've tried adding a table of what I mean but since I'm dealing with a Matrix the screenshots felt like it was the best way to explain while adding the queries in it.
I refrained from uploading the pbix file or any other queries, since the point is to avoid sensitive data as you advised.
Please let me know if this helps or if there's some other way I could help provide more information.
You cannot mix text and numbers in your output unless you format your numbers as text too.
- SeungLee951 year ago
Microsoft Employee
Thank you lbendlin,
And in that case if the numbers were text too then the SUM wouldn't be possible anyways since it's of text format right?
Appreciate the clarification/confirmation on this.
- lbendlin1 year ago
Super User
you can still do your math to arrive at the totals but the output format of that math needs to be text.
- SeungLee951 year ago
Microsoft Employee
lbendlin - May I ask how/what you mean on how to achieve that?
I don't think there'd be any issue if the output format was changed if it was consistent (for every row/level that it's showing for)