Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hello
I am trying to filter a visual to show Employees who's birthday appears in the selected month in a slicer. I have the below measure which works partially, but only when the measure is added to the visual. i also have the measure set to Is 1 in the filter pane. I want to only add it to the Filter Pane of the visual and choose 1. But when I remove the measure from the visual everything returns blank. What Is missing here? I also want the measure to ignore any Year selected in the Year Slicer, that's why I have ALL(DIM_Date)
IF (
HASONEVALUE ( DIM_Date[MonthNo] ),
IF (
MONTH (
CALCULATE (
MAX ( 'Employment'[DateofBirth] ),
ALL ( DIM_Date ),
USERELATIONSHIP ( 'DIM_Date'[Date], 'Employment'[DateofBirth] )
)
) = SELECTEDVALUE ( DIM_Date[MonthNo] ),
1,
0
),
BLANK ()
)
Thanks
Solved! Go to Solution.
Hi, @JB_AT
May I ask if this is the expected output you are looking for? Based on your description, I have created many measures to achieve the effect you are looking for. Following picture shows the effect of the display.
Measures:
EmployeeBirthday =
VAR _selectedMonth =
SELECTEDVALUE ( 'Month'[Month] )
VAR _EmpBirthdayMonth =
CALCULATE (
COUNTROWS ( Employment ),
FILTER ( Employment, Employment[Birthday].[MonthNo] = _selectedMonth )
)
RETURN
IF ( ISFILTERED ( 'Month'[Month] ), _EmpBirthdayMonth, 1 )
If this does not work, could you please share some sample data without sensitive information and expected output.
How to provide sample data in the Power BI Forum - Microsoft Fabric Community
Best Regards,
Yang
Community Support Team
If there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly.
If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!
How to get your questions answered quickly -- How to provide sample data in the Power BI Forum
Hi, @JB_AT
May I ask if this is the expected output you are looking for? Based on your description, I have created many measures to achieve the effect you are looking for. Following picture shows the effect of the display.
Measures:
EmployeeBirthday =
VAR _selectedMonth =
SELECTEDVALUE ( 'Month'[Month] )
VAR _EmpBirthdayMonth =
CALCULATE (
COUNTROWS ( Employment ),
FILTER ( Employment, Employment[Birthday].[MonthNo] = _selectedMonth )
)
RETURN
IF ( ISFILTERED ( 'Month'[Month] ), _EmpBirthdayMonth, 1 )
If this does not work, could you please share some sample data without sensitive information and expected output.
How to provide sample data in the Power BI Forum - Microsoft Fabric Community
Best Regards,
Yang
Community Support Team
If there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly.
If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!
How to get your questions answered quickly -- How to provide sample data in the Power BI Forum
Check out the July 2025 Power BI update to learn about new features.
User | Count |
---|---|
23 | |
8 | |
7 | |
6 | |
6 |
User | Count |
---|---|
28 | |
12 | |
10 | |
10 | |
6 |