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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Anonymous
Not applicable

Hide line based on filter in Line and Clustered bar chart

Hi Experts,

 

Need ur help in this issue.

I am working with Line and Clustered bar graph, which shows sales in each month representing Bars. We have a slicer named "City". For some cities we have a "Target Value" which is being represented as Line in the graph.

Now the issue is, for some cities, we do not have Target, that means, we do not want to show the Target Line in the Graph. In the data source, for these cities values are "NULL". 

Please advise, how can we hide and show the Target Line based on the selection of City.

 

Thanks.

 

Query.png

 

 

 

1 REPLY 1
v-piga-msft
Resident Rockstar
Resident Rockstar

Hi @Anonymous ,

 

By my test, if you don't have the target values for the city, if you select the city option under slicer, it will not show the target line in Line and Clustered bar graph.

 

Assuming that you have the data sample below.

 

data sample.PNG

 

 

Here is the output.

 

Untitled.png

If you still need help, please share a dummy pbix file which can reproduce the scenario, so that we can help further investigate on it? You can upload it to OneDrive and post the link here. Do mask sensitive data before uploading.)

 

Best  Regards,

Cherry

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

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 2025 Power BI update to learn about new features.

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors
Top Kudoed Authors