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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Remove year from visual if no data

Hello everyone, it's my first post here, I'm quite new to Power Bi and still discovering it. 

 

I do have a problem, hope you can help me.

 

I have some data for some years, 2018, 2019,  no data for 2020, blank space for 2021 - to be added in soon.

 

For some reason when I generate the graph I get 2020 included in the graph even if there is no data associated with it, I would like to take 2020 out.  

 

Photos attached.

 

Andru1994_0-1634828782547.png ,

Andru1994_2-1634828915076.png

 

Hope you can help

 

Many thanks ! 

 

1 ACCEPTED SOLUTION
Yggdrasill
Responsive Resident
Responsive Resident

Set the filter "on this visual" for "Numbers" to not blank and not 0

Yggdrasill_0-1634829158776.png

 

Alternitavely you can edit the measure you're using and use IF() statement like so:

Numbers = 
VAR _numbers = SUM(Numbers)
RETURN
IF( ISBLANK (_numbers) || _numbers = 0, BLANK(), _numbers)

 

View solution in original post

2 REPLIES 2
Anonymous
Not applicable

Thank you very much

Yggdrasill
Responsive Resident
Responsive Resident

Set the filter "on this visual" for "Numbers" to not blank and not 0

Yggdrasill_0-1634829158776.png

 

Alternitavely you can edit the measure you're using and use IF() statement like so:

Numbers = 
VAR _numbers = SUM(Numbers)
RETURN
IF( ISBLANK (_numbers) || _numbers = 0, BLANK(), _numbers)

 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.