cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Virtual_Ames Regular Visitor
Regular Visitor

How to deal with a "(BLANK)" value in a card visualization

My dashboard showed "(BLANK)" as the value in a card visualization - when I really wanted to see "0".

 

Is there a best practice to deal with this, or a simple way to adjust this?  

 

Here is my current solution.

 

Note: This does not seem to be a data type issue. The card is calling on a measure that is calculated as follows:

 

          Total CRs that have moved to P = CALCULATE([Total CRs - for calculations], 'Release_CRs_Systems (CRs Moved Only)'[Friendly System Name] = "P")

 

2) The data type for "Total CRs - for caculations" is "Whole Number" 

3) [Total CRs - for calculations] is a SUM function - type "Whole Number"

 

CURRENT SOLUTION:

 

Create a new measure that evaluates [Total CRs that have moved to P] and uses IF(ISBLANK)

    

     DISPLAY CALC FOR CR IN P =

        IF( ISBLANK('Release_CRs_Systems (CRs Moved Only)'[Total CRs that have moved to P])
        , 0
        , ( 'Release_CRs_Systems (CRs Moved Only)'[Total CRs that have moved to P]))

 

***** 

 

Can anyone provide a more elegant solution?

28 REPLIES 28
Virtual_Ames Regular Visitor
Regular Visitor

How to deal with a "(BLANK)" value in a card visualization

I had an issue with a dashboard showing "(BLANK)" as the value in a card visualization - when I really wanted to see "0".

 

If someone has a more elegant solution - I'd like to hear it - but here is my current solution.

 

PROBLEM:

 

     Card Visualization shows "(BLANK)" when a numerical value is desired.

 

 

 

 

Super User
Super User

Re: How to deal with a "(BLANK)" value in a card visualization

@Virtual_Ames I deal with this the same way... IF ( ISBLANK...

Super User
Super User

Re: How to deal with a "(BLANK)" value in a card visualization

@Virtual_Ames I was wondering the same a little over a month ago - got only one response - look here

 

http://community.powerbi.com/t5/Desktop/Blank-in-Card-Multi-row-Card/m-p/21946

Virtual_Ames Regular Visitor
Regular Visitor

Re: How to deal with a "(BLANK)" value in a card visualization

Thanks - that is a bit easier, and appreciated. 

 

Still hoping for an easier way - if not, perhaps this would be a feature request as this seems to imply that for every card where I do not want to see "(BLANK)" when certain filters are applied - I need to create a new measure and apply the IF

Super User
Super User

Re: How to deal with a "(BLANK)" value in a card visualization

Blank normally indicates the absence of any records that match the result.  I guess you could just write an if statement like this

 

New Measure = if(ISBLANK([Original Measure]),0,[Original Measure])



* Matt is a Microsoft MVP (Power BI) and author of the Power BI Book Supercharge Power BI.
Moderator v-qiuyu-msft
Moderator

Re: How to deal with a "(BLANK)" value in a card visualization

Hi @Virtual_Ames,

 

As sugegsted by @Sean and @MattAllington, we need to use =IF(ISBLANK...) to force blank values as 0. Or you can replace all blank values as 0 when you retrieve data from source table. Currently, the Card visualization will not trace blank value as 0.

 

If you have any question, please feel free to ask.

 

Best Regards,
Qiuyun Yu

Community Support Team _ Qiuyun Yu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
ReubenLam Frequent Visitor
Frequent Visitor

Re: How to deal with a "(BLANK)" value in a card visualization

I'm trying this method with a DISTINCTCOUNT and I'm still getting blanks.

 

Vendor Count:=IF(ISBLANK(DISTINCTCOUNT([Vendor Sourcing HierarchyVendor Sourcing HierarchyVendorid])),0,DISTINCTCOUNT([Vendor Sourcing HierarchyVendor Sourcing HierarchyVendorid]))

 

 

I have a list of stores in my rows, and time period as columns. Some periods, don't have data, some do.  The ones that don't have any data (No Values) show up as blanks.  I want to seed the blanks with 0's

 

Thoughts/Help?


@MattAllington wrote:

Blank normally indicates the absence of any records that match the result.  I guess you could just write an if statement like this

 

New Measure = if(ISBLANK([Original Measure]),0,[Original Measure])


 

Highlighted
Renaud Regular Visitor
Regular Visitor

Re: How to deal with a "(BLANK)" value in a card visualization

Hello,

 

inspired by this article explaining the blank value:

https://www.sqlbi.com/articles/blank-handling-in-dax/

 

i simply added a +0 after my expression and it works, since <blank> + 0 = 0.

Instead of Measure = expression,

i simply write it: Measure = expression + 0

 

this avoids repeating twice the expression in the measure definition

Surendra_thota Regular Visitor
Regular Visitor

Re: How to deal with a "(BLANK)" value in a card visualization

Hi

We also got the same case , did you got the solution for your issue . Please suggest me if you the solution