Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
Hello all 🙂
My user story: I would like to return values based on the following (in DAX)-->
THEN --> return 0 else 1.
When I say "date slicer" I am refering to the visualization:
The field I am using for the data slicer comes from a separate calendar table ("CalendarTable") I created within PowerBI.
The formula I thought would work to meet the goals in the story above is:
CalculatedColumn = IF(AND(Tasks[dates.due]>FIRSTDATE(CalendarTable[Date]), Tasks[dates.start]<LASTDATE(CalendarTable[Date])), 0, 1)
The result with this code is that no matter how I set my date slicer, it always returns 0.
Thank you,
-L
Solved! Go to Solution.
Hi @love
Calculated ccolumns do not react to slicer selections
May be you could try a MEASURE instead
MEASURE =
IF (
AND (
SELECTEDVALUE ( Tasks[dates.due] ) > MIN ( CalendarTable[Date] ),
SELECTEDVALUE ( Tasks[dates.start] ) < MAX ( CalendarTable[Date] )
),
0,
1
)
/push
Hi @love
Calculated ccolumns do not react to slicer selections
May be you could try a MEASURE instead
MEASURE =
IF (
AND (
SELECTEDVALUE ( Tasks[dates.due] ) > MIN ( CalendarTable[Date] ),
SELECTEDVALUE ( Tasks[dates.start] ) < MAX ( CalendarTable[Date] )
),
0,
1
)
Thank you very much @Zubair_Muhammad, your solution worked perfectly. Also great info about the columns, thanks again!
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.