Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.
Hi folks,
Hope you can help.
I'm new(ish) to Power Bi, being self taught via videos, reading and good old fashioned trial and error.
I've created a line and stacked chart, with a constant line for the SLA target (10 days).
This is linked to a date slicer to adjust accordingly.
Prior to adding the constant line it worked perfectly, however, now I've added the line it adds the previous years month but with blank data and I've not changed the slicer settings (there is data available for 2023). Once I remove the constant line, it reverts back to normal and no issues. Can someone please assist? I've included screen prints of the graph in original state and how it switches once you add the constant line. Thanking youin advance
Without constant line the data works.
When constant line is added, it randomly adds last years month with blank data.
Solved! Go to Solution.
Hi @ME_1976,
If you go to the options of the chart one of the last options is reference line, there you add a new line as a constant, use your measure on that and everything should work
https://learn.microsoft.com/en-us/power-bi/transform-model/desktop-analytics-pane
Regards
Miguel Félix
Proud to be a Super User!
Check out my blog: Power BI em PortuguêsHi @ME_1976 ,
How are you setting up the flat line? is it a measure? Can you share the syntax please.
Regards
Miguel Félix
Proud to be a Super User!
Check out my blog: Power BI em PortuguêsI just added a new measure using 'constant line = 10' then added it to Line y-axis.
Hi @ME_1976 ,
I did some tests on my side and adding a measure on the chart it works correctly and nothing is added.
How are the other two metrics calculated? I believe that you cam have a filter context transition that is not getting picked up by this new measure.
Is the calendar table related with your fact table?
Regards
Miguel Félix
Proud to be a Super User!
Check out my blog: Power BI em PortuguêsHi, I'm not 100% sure what you mean (still getting to grips with Power Bi and the technical wording). The date range is within a slicer, with the dates running continuously for each end of month and forms part of the data. If that makes sense. I'm mindful of the data within the document, so I've attached screen grabs of the settings to see if that helps answer the question.
Hi @ME_1976,
If you go to the options of the chart one of the last options is reference line, there you add a new line as a constant, use your measure on that and everything should work
https://learn.microsoft.com/en-us/power-bi/transform-model/desktop-analytics-pane
Regards
Miguel Félix
Proud to be a Super User!
Check out my blog: Power BI em Português