Don't miss your chance to take the Fabric Data Engineer (DP-700) exam on us!
Learn moreNext up in the FabCon + SQLCon recap series: The roadmap for Microsoft SQL and Maximizing Developer experiences in Fabric. All sessions are available on-demand after the live show. Register now
Hello everybody.
I have several measures that calculate some total sums for numerous situations.
Some of them are displaying "(Blank)" if there is no value.
How can I replace this with a "0" ?
I mean, of course, I could do a pretty simple IF ...;0; ...
But is there are more efficient and elegant way?
Is there maybe a function for that?
Or from a dax performance point of view, what is the best way?
@joshua1990 If this has solved your question. Please can you accept a solution.
Multiple people have already suggested the "+0" solution to this. Depending on the columns you are using in your visual, you may see many more rows/columns show up. Visuals automatically filter out blanks, so adding 0 will return a result in those situations that would have been filtered out. You may need to add a separate filter to the visual, etc. to keep remove those unneeded ones again.
Regards,
Pat
To learn more about Power BI, follow me on Twitter or subscribe on YouTube.
Yes, I see. Now I see 0 values for the whole year.
I should consider that somehow 😕
Maybe a conditional format if the value is blank would solve that challenge?
If you are seeing more zeros than you wanted, you can use IF logic to get your desired result. For example, a date requirement or if another measure is blank or not, etc.
NewMeasure = IF(some logic, [Measure] + 0, [Measure])
If this works for you, please mark it as the solution. Kudos are appreciated too. Please let me know if not.
Regards,
Pat
To learn more about Power BI, follow me on Twitter or subscribe on YouTube.
Hi @joshua1990 ,
Try
Measure = SUM('Table'[Sales]) + 0
or
Regards,
Harsh Nathani
Appreciate with a Kudos!! (Click the Thumbs Up Button)
Did I answer your question? Mark my post as a solution!
You'll have to write out a measure for your calculation then add +0 to the end for example.
= SUM(Sales[Amt])+0
This essentially says calculate this amount then add 0.
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.
Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
| User | Count |
|---|---|
| 9 | |
| 6 | |
| 3 | |
| 2 | |
| 1 |
| User | Count |
|---|---|
| 21 | |
| 14 | |
| 11 | |
| 6 | |
| 5 |