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!Vote for your favorite vizzies from the Power BI Dataviz World Championship submissions. Vote now!
I have this chart with a constant line at 4. The chart is using relative date filtering so 2018 months will come into the chart as they occur. I would like to be able to change the constant value in 2018 to 4.5, but have it remain at 4 for 2017. Not sure this is possible, a different way to maybe go about it is using a chart with a line value and maybe use a 4 and 4.5 from a field within the data tables.
Thanks for the help.
Solved! Go to Solution.
Sorry, my bad, wrap your YEAR() in a MAX function. It's a measure, so you need to do some kind of aggregation.
Measure = IF(MAX(YEAR(Table[Date]))<2018,4,4.5)
I would go with a combination line/column chart and use a measure for the line like:
Measure = IF(YEAR(Table[Date])<2018,4,4.5)
The issue with that is my date column has multiple values so it gives me an error. I think I'd need to return a column that returns a 4.5 for the first entry in 2018 and blank in the rest of 2018 values. Similarly return a 4 for the first non 2018 date and the rest blanks. Any ideas?
Hi @jshinnenkamp,
Please follow the solution @Greg_Deckler posted. Please share the sample table and list the expected result if you still have other issues.
Best Regards,
Angelia
Sorry, my bad, wrap your YEAR() in a MAX function. It's a measure, so you need to do some kind of aggregation.
Measure = IF(MAX(YEAR(Table[Date]))<2018,4,4.5)
Vote for your favorite vizzies from the Power BI World Championship submissions!
If you love stickers, then you will definitely want to check out our Community Sticker Challenge!
Check out the January 2026 Power BI update to learn about new features.
| User | Count |
|---|---|
| 60 | |
| 53 | |
| 42 | |
| 20 | |
| 16 |
| User | Count |
|---|---|
| 123 | |
| 104 | |
| 44 | |
| 32 | |
| 24 |