Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Don't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.

Reply
Azar503
Regular Visitor

Need help for DAX measure

Hi,

I need help in calculatind date measure.
I have Date Slicer that takes up dates From and To.
Ex - From 3/Sep/2019 To - 3/Sep/2021


1. Calculate the no of years for the given Date Range
No of Months is 48 and when divided by 12 it is 4 (no of years)

Ex:
FromToNo of MonthSplit
01-Sep-1930-Sep-23484


Expected Out Put in matrix
NameSep-19-sep  20Sep-20 to sep 21Sep-21 to sep 22Sep-22 to sep 23
A23203533
b34403445
c44505540
d34254450



If the To Date is 31 0ct 23, we need the column header to show in months in Last column as highligted.

NameSep-19-sep 20Sep-20 tosep 21Sep-21 to sep 22Sep-22 to sep 2331-Oct-23
A2320353333
b3440344545
c4450554040
d3425445050

Row : Name
Column: Date it will be split accordingly by selected Date filters.
Vales : Sales amount

Please help me to achieve this requirement.


Thanks and Regards,
Azar.

------------------------------
Mohamed Azarudeen.

------------------------------
 
 

 

1 REPLY 1
v-easonf-msft
Community Support
Community Support

Hi, @Azar503 

Not quite sure what you need, can you explain more specifically the logic of the measure you need to create? Please provide your original data sheet for research.

 

Best Regards,
Community Support Team _ Eason

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

Jan25PBI_Carousel

Power BI Monthly Update - January 2025

Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.

Jan NL Carousel

Fabric Community Update - January 2025

Find out what's new and trending in the Fabric community.