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!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
Hi,
Is there any way to perform Measure with a variable that will go on loop for last 6 months ?
Example :
Measure formula is : runs/ (value in nth month).
How will it look in table or dashboard :
| month -6(nov,2021) | month-5(dec,2021) | month-4(Jan) | month-3(Feb) | month-2(March) | current month(April) |
| 45 | 65 | 75 | 85 | 95 | 40 |
Here the months will be changing based on live data and so will the values indifferent month.
Solved! Go to Solution.
Hi @FaisalImam ,
If your month values are not in a single column, I'd suggest you firstly go to Power Query Editor and use "Unpivot" to transform data:
Best Regards,
Eyelyn Qin
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @FaisalImam ,
If your month values are not in a single column, I'd suggest you firstly go to Power Query Editor and use "Unpivot" to transform data:
Best Regards,
Eyelyn Qin
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
@FaisalImam
Can you share some sample data with the desired output to have a clear understanding of your question?
Mention whether you want a calculated column or measure.
You can either paste your data in the reply box or save it in OneDrive, Google Drive, or any other cloud-sharing platform and share the link here.
⭕ Subscribe and learn Power BI from these videos
⚪ Website ⚪ LinkedIn ⚪ PBI User Group
@Fowmy ,
See I will be doing a Measure .
Suppose Measure is : Critical incident in the month/ total incident in the month. Now I need to calculate this and show in the table for the last six months.
We will be extracting data from Snow flake or Service Now for last 6 months and using months in our formula to separate the data on monthly basis.
We are going to use live data and hence the months are going to chnge.
Example :
For this month :
Table
| Metrics | March Data | Feb Data | Jan Data |
| incident resolution | 45% | 36% | 25% |
Next Month (May)
| Metrics | April data | March data | Feb data |
| incident resolution | 43% | 45% | 36% |
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!