Skip to main content
cancel
Showing results for
Search instead for
Did you mean:

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Post Prodigy

## 0 instead of (Blank)

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?

7 REPLIES 7
Anonymous
Not applicable

@joshua1990 If this has solved your question. Please can you accept a solution.

Employee

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

Did I answer your question? Mark my post as a solution! Kudos are also appreciated!

To learn more about Power BI, follow me on Twitter or subscribe on YouTube.

@mahoneypa HoosierBI on YouTube

Post Prodigy

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?

Employee

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

Did I answer your question? Mark my post as a solution! Kudos are also appreciated!

To learn more about Power BI, follow me on Twitter or subscribe on YouTube.

@mahoneypa HoosierBI on YouTube

Super User

HI @joshua1990 ,

Just modify your measure as follows: SUM(Tablename[Column]) + 0

Thanks,

Pragati

Best Regards,

Pragati Jain

Did I answer your question? Mark my post as a solution! This will help others on the forum!

Appreciate your Kudos!!

Proud to be a Super User!!

Community Champion

Hi @joshua1990 ,

Try

Measure = SUM('Table'[Sales]) + 0

or

COALESCE Sales = COALESCE([Total Sales],0)

Regards,
Harsh Nathani

Appreciate with a Kudos!! (Click the Thumbs Up Button)
Did I answer your question? Mark my post as a solution!

Anonymous
Not applicable

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.

## Helpful resources

Announcements

#### New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

#### Power BI Monthly Update - May 2024

Check out the May 2024 Power BI update to learn about new features.

#### Fabric certifications survey

Certification feedback opportunity for the community.

Top Solution Authors
Top Kudoed Authors