This time we’re going bigger than ever. Fabric, Power BI, SQL, AI and more. We're covering it all. You won't want to miss it.
Learn moreLevel up your Power BI skills this month - build one visual each week and tell better stories with data! Get started
Hi,
I would like to be able to compare a data organized by date and zone, with the year before, or the year before that, etc.
I would like to be able to chose the comparison period with a slicer.
As you can see on the picture, the orange line is chosen period of 2023. The yellow line is the comparison period of 2021. The 2 lines are in the same graph, and i can compare them. But I could have chosen another year 2020, 2022...
But look at my dataset on the 2nd picture : I have only one column date, one column zone and one column volume. I can't make any changes on the files themselves because there are too many. I want to make it on PowerBI.
Please help me I really don't know how to do this
Thanks a lot !
🆙 @Ritaf1983 I'm begging you haha, if you had a little more time for me I'd be so grateful !
Hi @Jackisover
Sorry , i afraid that i don't know how to help more than i tried 😔
Thank you @Ritaf1983 but actually I think this solution doesnt work because my date is in my graph, and not only in a slicer
Hi @Jackisover
Please refer to the linked tutorial.
It is ok to have 1 column for a date in your fact table, you can work with 2 calendar tables.
https://www.youtube.com/watch?v=40AZos5hjko
If this post helps, then please consider Accepting it as the solution to help the other members find it more quickly
As I mentioned you need date tables for your model.
The link that i added is a good tutorial.
You can also take a look at my example in the attached pbix to follow i has very similar logic.
I added lines sheet for you.
Note that the X axis should be just month without year.
If this post helps, then please consider Accepting it as the solution to help the other members find it more quickly
Hello @Ritaf1983
I tried to do the same thing on my project, but I seem to have a problem. Actually, I need to display the daily datas, but I can't use the column date on my graph. So I tried to recreate a new string date, using DAY() and MONTH().
The comparison works great, with the slicer, but the basic line doesn't change with its slicer.
I think I'm close but I don't know what to change to get the solution.
Could you take a look at my pbix ? Thanks a lot !!
Thank you very much for your time and your example
I will try this and let you know if it works for me !
Check out the April 2026 Power BI update to learn about new features.
Sign up to receive a private message when registration opens and key events begin.
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
| User | Count |
|---|---|
| 38 | |
| 28 | |
| 27 | |
| 22 | |
| 18 |
| User | Count |
|---|---|
| 67 | |
| 36 | |
| 32 | |
| 25 | |
| 25 |