The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hi all,
Unsure if this is a feature within Power BI (or maybe this can be calculated within the Excel spreadsheet), but I would like to display data from the most recent 3 months when I refresh my data dashboard. I have a Power Automate workflow set up which gathers the data from a Microsoft Forms survey and saves it within an Excel spreadsheet on SharePoint. I refresh my data dashboard to display the monthly results for other data, but I would like to display the data from the most recent 3 months in one of my visuals (it is a basic visual displaying feedback in a 'Gauge' chart).
For example, for my June end monthly dashboard, I would like to display data from the months of April, May, & June.
Then, for my July end monthly dashboard, I would like to display data from the months of May, June, & July. And so on...
I have attached a very basic example table below which displays the way the dates are stored in the Excel spreadsheet. I can also provide more info for this question if need be! Thanks in advance!
Date | Did you enjoy the event? | Did you find the event useful? | Any suggestions? |
10/01/2023 | Yes | Yes | More content |
17/01/2023 | Yes | Yes | More content |
04/02/2023 | Yes | No | More speakers |
21/02/2023 | No | Yes | No |
22/02/2023 | No | Yes | More speakers |
15/03/2023 | No | Yes | No |
19/03/2023 | No | No | No |
28/04/2023 | Yes | No | Longer session |
29/04/2023 | No | Yes | More content |
01/05/2023 | Yes | No | More content |
07/05/2023 | Yes | No | More speakers |
Solved! Go to Solution.
Hi @adamcairns ,
According to your description, here are my steps you can follow as a solution.
(1) My test data is the same as yours.
(2) We can create a measure.
Flag =
var _end=EOMONTH(TODAY(),-2)
var _start= DATE(YEAR(_end),MONTH(_end),1)
return IF(MAX('Table'[Date])<=TODAY() && MAX('Table'[Date]) >= _start,1,0)
(3) Then the result is as follows.
When you perform a data refresh and the underlying data changes, the visual object displays only today's data from three months ago.
Best Regards,
Neeko Tang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @adamcairns ,
According to your description, here are my steps you can follow as a solution.
(1) My test data is the same as yours.
(2) We can create a measure.
Flag =
var _end=EOMONTH(TODAY(),-2)
var _start= DATE(YEAR(_end),MONTH(_end),1)
return IF(MAX('Table'[Date])<=TODAY() && MAX('Table'[Date]) >= _start,1,0)
(3) Then the result is as follows.
When you perform a data refresh and the underlying data changes, the visual object displays only today's data from three months ago.
Best Regards,
Neeko Tang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.