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
mjmar025
Helper I
Helper I

Data Label Question

I have a bar chart with a date on the x-axis and a $ amount as the value. When I make a year selection in a slicer, several of the values in the bar chart go to zero. Is it possible to remove the data labels in the bar chart when the value is 0?

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Rewrite your measure to use a variable and an IF statement to blank out zeroes. Assuming your measure is something like:

 

Sales = SUM(SalesTable[Amount])

...you would rewrite it as:

 

Sales = VAR result = SUM(SalesTable[Amount])
RETURN IF(result = 0, BLANK(), result)

This will turn zeroes into blanks, which do not show up in data labels.

View solution in original post

2 REPLIES 2
v-jiascu-msft
Microsoft Employee
Microsoft Employee

Hi @mjmar025,

 

Could you please mark the proper answer if it's convenient for you? That will be a help to others.

 

Best Regards!
Dale

Community Support Team _ Dale
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Anonymous
Not applicable

Rewrite your measure to use a variable and an IF statement to blank out zeroes. Assuming your measure is something like:

 

Sales = SUM(SalesTable[Amount])

...you would rewrite it as:

 

Sales = VAR result = SUM(SalesTable[Amount])
RETURN IF(result = 0, BLANK(), result)

This will turn zeroes into blanks, which do not show up in data labels.

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.