Join us for an expert-led overview of the tools and concepts you'll need to pass exam PL-300. The first session starts on June 11th. See you there!
Get registeredPower BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.
Hello , as per the below screenshot i am trying to create a graph where i can show the Y-1 values as well as the last 12 months values however i am unable to remove the previous periods from the graph with a slicer or with filters, when i do so i lose the values for Y-1, can anyone possibly assist me with this? Many thanks
@Anonymous , Based on what I got , a measure like this should help
Year behind Sales = CALCULATE(SUM(Sales[Sales Amount]),dateadd('Date'[Date],-1,Year))
Year behind Sales = CALCULATE(SUM(Sales[Sales Amount]),SAMEPERIODLASTYEAR('Date'[Date]))
Hello Amtichandak, indeed i have used the second formula you have mentioned however what i am looking to do i hide the 2020 values on my x axis and i am unable to do so with filtering or slicing as this will remove the values on the orange line (the Y-1 line)
Hi @Anonymous ,
Which field of which table is applied to the x-axis on your line chart visual? Is it from the date dimension table? Is it possible to try to apply a visual-level filter in Filters panel with the condition (date>=2021.1.1)?
If the above one is not working, please provide some data of involved tables which applied on the line chart visual and the Fields setting of line chart visual. And please also share the related formulas if it involve any measure. Thank you.
Best Regards
@Anonymous , For that use a year slicer
Or filter using a column like
Year Type = Switch( True(),
year([Date])= year(Today()),"This Year" ,
year([Date])= year(Today())-1,"Last Year" ,
Format([Date],"YYYY")
)
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
84 | |
75 | |
68 | |
41 | |
35 |
User | Count |
---|---|
102 | |
56 | |
52 | |
46 | |
40 |