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

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
sahooak
Regular Visitor

How create a stacked bar chart 100% completion Line?

Hello Everyone,

I need help with this chart. We're currently migrating from Tableau to Power BI. I've to recreated a chart in Power BI that we originally built in Tableau.

In the bar chart, I'm showing shipment values, with status represented in the legend. On the right side, I'm displaying the forecasted shipment values for each category.

There's also a dotted line in the chart, which represents a constant 100% target line. As the actual shipment value for a category approaches its forecasted value, the corresponding bar moves closer to the dotted line, visually indicating the percentage of completion.

My question is:
Is there a way to replicate this behavior in Power BI, where the bars dynamically reflect how close the actual shipment values are to their forecasted targets, ideally by reaching toward the dotted line?

achecive this

sahooak_0-1760422839146.png
Best Regards,
Ak

 

1 ACCEPTED SOLUTION

@sahooak, sorry for the delay, I was travelling.

 

Please find attached an example. 

 

If it helped you, you can give kudos and accept it as a solution. 

View solution in original post

10 REPLIES 10
v-tejrama
Community Support
Community Support

Hi @sahooak ,

 

Thanks for sharing the details and the screenshot. I tried to recreate the setup using a sample dataset with the same field structure, and the visual appears to behave as expected. The combination of a stacked column and a line chart works correctly when using one measure on the column axis Sum of ShipmentValue and multiple measures on the line axis Target 100% and Shipment %, with Category on the shared axis and Status on the legend.

 

If you’re seeing a mismatch, missing line, or label overlap, it might be due to how the data types or aggregation levels are set up. It’s worth checking that both Target 100% and Shipment % are formatted consistently as decimal or percentage values and that the secondary axis is properly scaled. You could also try removing and re-adding one of the measures to refresh the visual binding, as Power BI occasionally holds onto an old field reference when visuals are edited multiple times.

 

If the issue still persists after confirming those settings, please share a brief description of the behavior you’re seeing for example, whether the line disappears, the scale is incorrect, or data labels overlap. That will help determine whether this is a reproducible product issue or something related to the underlying data model.

This is the answer I am providing. Can you please validate if this workaround is working properly for you? Let me know if you have any other queries

Please find the attached PBIX and Screenshort file for your reference.

vtejrama_0-1760510700165.png

 

 

Best Regards,
Tejaswi.
Community Support




MattiaFratello
Super User
Super User

Hi @sahooak ,

 

could this work?

 

MattiaFratello_0-1760427008267.png

 

If yes, please see the steps below:

 

% = sum('Table'[Actual])/sum('Table'[Target])

 

MattiaFratello_0-1760427108233.png

 

MattiaFratello_1-1760427135524.png

 

 

MattiaFratello_2-1760427152277.png

 

 

And then create the multi card on the right

 

MattiaFratello_3-1760427185264.png

 

 

If it helped, please accept it as a solution

 

@MattiaFratello  Thank you for your help. Can you please share PBIX file. So it will be helpful

@sahooak, sorry for the delay, I was travelling.

 

Please find attached an example. 

 

If it helped you, you can give kudos and accept it as a solution. 

GrowthNatives
Solution Supplier
Solution Supplier

Hi @sahooak ,
You can follow these steps to get the desired result for your chart 
but make sure you have fields like: Category, Actual Shipment, Forecast Shipment

1. Create Measures

DAX 
% Achieved = DIVIDE([Actual Shipment], [Forecast Shipment], 0)

This gives you the ratio between actual and forecast.

2. Create a Bar Chart

Use a Clustered Bar Chart (horizontal).

X-axis: % Achieved

Y-axis: Category

3.Add a Constant Line

Go to Analytics Pane → Constant Line → Value = 1 (or 100%)

Style it as dotted or dashed

Label it “Target (100%)”

4. Format

Set X-axis to show percentage values (0–1 or 0–100%).

Color the bars based on Status (using the Legend).

Adjust transparency or data labels as needed.

Hope this solution helps you make the most of Power BI! If it did, click 'Mark as Solution' to help others find the right answers.
💡Found it helpful? Show some love with kudos 👍 as your support keeps our community thriving!
🚀Let’s keep building smarter, data-driven solutions together!🚀 [Explore More]



Hello @GrowthNatives  Thank you for your help. How can i add forecast value after the constant line?

Yes @sahooak 
We’ll combine:
• Bar chart for Actual % Achieved
• Line (or marker) for Forecast
• Constant dotted line at 100%

Create core measures 

DAX 
% Achieved = 
DIVIDE([Actual Shipment], [Forecast Shipment], 0)

Forecast % = 1   // represents the target 100% line logically


If you want to display Forecast shipment values as an actual bar (beyond 100%), also create:

DAX 
Forecast Shipment % =
DIVIDE([Forecast Shipment], [Forecast Shipment], 0)   // always 1, but used for scaling alignment


or, if you want to show absolute forecast values on a secondary axis:

DAX
Forecast Value = [Forecast Shipment]


Hope this solution helps you make the most of Power BI! If it did, click 'Mark as Solution' to help others find the right answers.
💡Found it helpful? Show some love with kudos 👍 as your support keeps our community thriving!
🚀Let’s keep building smarter, data-driven solutions together!🚀[Explore More]




Hello @GrowthNatives For forecast value I need to use Multi-row card, right? Then I need to group it to the bar char.

Thank you,
Ak

Hi @sahooak , If you want the forecast values to appear visually aligned with bars then use the Clustered Bar Chart (or Stacked Bar Chart if showing remaining %).

Add both measures:
• Actual % (bar length)
• Forecast Value (as a separate measure or label)

In Data Labels → Customize Series:
• Turn on labels for Forecast Value only.
• Position them “Outside end” of the bar.
• Format as currency, or whatever unit your forecast uses.

Add your dotted 100% constant line (from Analytics pane).

Hope this solution helps you make the most of Power BI! If it did, click 'Mark as Solution' to help others find the right answers.
💡Found it helpful? Show some love with kudos 👍 as your support keeps our community thriving!
🚀Let’s keep building smarter, data-driven solutions together!🚀[Explore More]

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

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

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.