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.
Solved! Go to Solution.
I believe a colleague found the right solution. If anyone else stumbles across this question, here is a solution:
Create the following calculated column:
Flag current month if max day is <15 =
VAR maxday_day = DAY(max('Date Table'[Date]))
VAR latestmonth = MONTH(max('Date Table'[Date]))
VAR latestyear = YEAR(max('Date Table'[Date]))
RETURN
IF(
AND(
AND( maxday_day <= 14,
'Date Table'[Month]=latestmonth
),
'Date Table'[Year]=latestyear
),
1,
0 )
You would then drag this column onto the filter pane for the required visual and make is "Show anything greater than 0"
I believe a colleague found the right solution. If anyone else stumbles across this question, here is a solution:
Create the following calculated column:
Flag current month if max day is <15 =
VAR maxday_day = DAY(max('Date Table'[Date]))
VAR latestmonth = MONTH(max('Date Table'[Date]))
VAR latestyear = YEAR(max('Date Table'[Date]))
RETURN
IF(
AND(
AND( maxday_day <= 14,
'Date Table'[Month]=latestmonth
),
'Date Table'[Year]=latestyear
),
1,
0 )
You would then drag this column onto the filter pane for the required visual and make is "Show anything greater than 0"
Hi @alicek ,
Did you want to show date from 1-14 if today is after 15 every month? You can use the following measure:
Current Month and Day 15 =
IF (
DAY ( TODAY () ) <= 14,
"TOO EARLY TO SHOW",
IF (
MAX ( Date[Date] ) <= DATE ( YEAR ( TODAY () ), MONTH ( TODAY () ), 15 )
&& MAX ( Date[Date] ) <= DATE ( YEAR ( TODAY () ), MONTH ( TODAY () ), 1 ),
"SHOW"
)
)
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Best Regards,
Dedmon Dai
Hi Dedmon! I'm not sure this would work because:
1. I think the second && MAX should be => not <=? as in, if it's between 1 and 15 - the way you have it written there is if the latest/max date of the date table is both less than or equal to the 15th and less than or equal to the 1st.
2. The first part of the IF statement would make any date in the date table that had the "day" number as less than 14 always say "too early to show." For example, if today was June 14th, May 14 would also meet the criteria of DAY(TODAY()) <= 14
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 | |
97 | |
85 | |
70 | |
61 |
User | Count |
---|---|
151 | |
121 | |
104 | |
87 | |
67 |