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!Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes! Register now.
I am having a calender where the last friday of the month is end of the month so i am using some DAX to show current month filter in some reports but oct 27th is the last day of the month end and from 28th oct should come in november. I am using a DAX where it is showing current month untill 31st oct. can anyone help me please.
Hi @Srinivas3350 ,
Please try code as below to create a calendar table.
Calendar =
VAR _STEP1 =
ADDCOLUMNS (
CALENDAR ( DATE ( 2023, 01, 01 ), DATE ( 2023, 12, 31 ) ),
"Year", YEAR ( [Date] ),
"Month", MONTH ( [Date] ),
"YearMonth",
YEAR ( [Date] ) * 100
+ MONTH ( [Date] ),
"MonthName", FORMAT ( [Date], "MMMM" ),
"WeekDay", WEEKDAY ( [Date], 2 ),
"WeekDayName", FORMAT ( [Date], "DDDD" )
)
VAR _STEP2 =
ADDCOLUMNS (
_STEP1,
"Fiscal Year",
VAR _LASTFRIDAY =
MAXX (
FILTER ( _STEP1, [YearMonth] = EARLIER ( [YearMonth] ) && [WeekDay] = 5 ),
[Date]
)
RETURN
IF ( [Date] <= _LASTFRIDAY, [Year], YEAR ( EOMONTH ( [Date], +1 ) ) ),
"Fiscal Month",
VAR _LASTFRIDAY =
MAXX (
FILTER ( _STEP1, [YearMonth] = EARLIER ( [YearMonth] ) && [WeekDay] = 5 ),
[Date]
)
RETURN
IF ( [Date] <= _LASTFRIDAY, [Month], MONTH ( ( EOMONTH ( [Date], +1 ) ) ) )
)
RETURN
_STEP2
Result is as below.
Best Regards,
Rico Zhou
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @Anonymous , Thank you. I am already having this fiscal calender years but my measure is not working to show current fiscal month. could you help me in this measure to show current fiscal month. if it is current fiscal month 1 or 0
Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!
Check out the September 2025 Power BI update to learn about new features.
User | Count |
---|---|
9 | |
8 | |
6 | |
4 | |
3 |