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

Next 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

Reply
id013
Helper V
Helper V

X-axis not showing blanks

Hi,

 

So I have two clustered bar visuals, both show a percentage measure. However one shows a blank space to show where the fiscal period of P07 had a blank value whereas the other just doesn't show the period at all. 

 

id013_0-1605226788708.png

What I'm confused about is that in the bottom visual (pink bars), the numerator is blank for P07 but the denominator is not. And in the Top visual (multi colored bars), the numerator is also blank but the denominator is not. So how come one graph shows a blank but the other doesn't? The only difference I can find is the for the bottom visual, both the numerator and the denominator are sum measures (ie. CALCULATE(SUM etc), and the top visual both the numerator and the denominator are count measures (ie. CALCULATE(DISTINCTCOUNT etc). 

 

Is there something simple I'm missing here as to why the top visual doesn't show blanks on the x-axis and the bottom one does?

Thanks

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @id013 

Could you tell me if your problem has been solved? If it is, kindly Accept the helpful reply as the solution. More people will benefit from it. Or you are still confused about it, please provide me with more details about your table and your problem or share me with your pbix file from your Onedrive for Business.

 

Best Regards,

Rico Zhou

View solution in original post

4 REPLIES 4
amitchandak
Super User
Super User

@id013 , Depend on how you have handled the calculation. Need to know both the values. The best way is use divide with alternate value for A/B = divide(A,B,0) . This will handle divide by 0 and can give 0 in such case.

 

Can you share sample data and sample output in table format? Or a sample pbix after removing sensitive data.

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

So I think I figured it out, the graph that shows a blank, has the following formula for the numerator, CALCULATE(SUM(sales)) and the graph that doesn't show a blank has the following formula for the numerator CALCULATE(DISTINCTCOUNT(order_id)). I think a sum even if there's no values for the period will return a 0 but a count will return a blank. Does that sound right? 

Anonymous
Not applicable

Hi @id013 

Could you tell me if your problem has been solved? If it is, kindly Accept the helpful reply as the solution. More people will benefit from it. Or you are still confused about it, please provide me with more details about your table and your problem or share me with your pbix file from your Onedrive for Business.

 

Best Regards,

Rico Zhou

id013
Helper V
Helper V

I should also note that for both percent measures, I'm using the same DAX formula --> DIVIDE(Numerator, Denominator, 0)

Helpful resources

Announcements
New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

March Power BI Update Carousel

Power BI Community Update - March 2026

Check out the March 2026 Power BI update to learn about new features.