Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Experts,
I am new in Power BI - trying to explain my prob I am facing,
I wanted to bifurcate month from date Rate. i.e
Project start date - 1st Jan'18 to 31st Dec' 19 - so # of month i want in 2018 column = 12 & 2019 = 12
so on each row of the table, I want no of Month in Column wise (in Year formate)
Thanks
Kaush
Solved! Go to Solution.
Hi @rekaush
You could try the following calculated column. Just change the VAR myYear variable to 2019 for the 2019 column
2018 Month = VAR myYear = 2018 VAR Months = SUMMARIZE( ADDCOLUMNS( CALENDAR( DATE(myYear,1,1), DATE(myYear,12,1) ), "Month", DATE( YEAR([Date]), MONTH([Date]), 1) ) ,[Month]) RETURN COUNTROWS( FILTER( Months, [Month]>=EARLIER(Projects[Project Start Date]) && [Month] <=EARLIER('Projects'[Project End Date]) ))
Hi @rekaush
You could try the following calculated column. Just change the VAR myYear variable to 2019 for the 2019 column
2018 Month = VAR myYear = 2018 VAR Months = SUMMARIZE( ADDCOLUMNS( CALENDAR( DATE(myYear,1,1), DATE(myYear,12,1) ), "Month", DATE( YEAR([Date]), MONTH([Date]), 1) ) ,[Month]) RETURN COUNTROWS( FILTER( Months, [Month]>=EARLIER(Projects[Project Start Date]) && [Month] <=EARLIER('Projects'[Project End Date]) ))
Thx Mate, Really helpful 🙂
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
113 | |
99 | |
75 | |
73 | |
49 |
User | Count |
---|---|
145 | |
109 | |
109 | |
90 | |
64 |