Check your eligibility for this 50% exam voucher offer and join us for free live learning sessions to get prepared for Exam DP-700.
Get StartedDon't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.
Hi Experts
When the user selects a slicer in Power BI i want the switch function to use
Solved! Go to Solution.
Hi @Invesco ,
I think your issue should be caused by the relationship between the column in slicer and your data table.
So when there is nothing selected in your slicer, due to the relationship, Power BI will always return the result in selected field.
I suggest you to create an unrelated Dimtable for slicer. And you need to add the filter from the slicer in [Test] and [Measure 1].
EX:
Test =
VAR _SELECT =
VALUES ( DimTable[ColumeName] )
RETURN
COUNTROWS (
SUMMARIZE (
FILTER (
dev_shc_shingrix_activity,
dev_shc_shingrix_activity[ColumeName] IN _SELECT
),
dev_shc_shingrix_activity[employee_mud_id],
dev_shc_shingrix_activity[external_hco_code]
)
) + 0
If this reply still couldn't help you solve your issue, please share a sample file with me. And you can show me a screenshot with the result you want. This will make it easier for us to find the solution.
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 @Invesco ,
I think your issue should be caused by the relationship between the column in slicer and your data table.
So when there is nothing selected in your slicer, due to the relationship, Power BI will always return the result in selected field.
I suggest you to create an unrelated Dimtable for slicer. And you need to add the filter from the slicer in [Test] and [Measure 1].
EX:
Test =
VAR _SELECT =
VALUES ( DimTable[ColumeName] )
RETURN
COUNTROWS (
SUMMARIZE (
FILTER (
dev_shc_shingrix_activity,
dev_shc_shingrix_activity[ColumeName] IN _SELECT
),
dev_shc_shingrix_activity[employee_mud_id],
dev_shc_shingrix_activity[external_hco_code]
)
) + 0
If this reply still couldn't help you solve your issue, please share a sample file with me. And you can show me a screenshot with the result you want. This will make it easier for us to find the solution.
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.
Please provide sample data (with sensitive information removed) that covers your issue or question completely in a usable format (not as a screenshot).
https://community.fabric.microsoft.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-...
Please show the expected outcome based on the sample data you provided.
https://community.fabric.microsoft.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447...
This allows members of the Forum to assess the state of the model, report layer, relationships, and any DAX applied.
Try the below.
Measure = IF(ISFILTERED(Columnname),MEASURE_1,Test )
Thanks for the feedback but not working when no filters are selected.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Prices go up Feb. 11th.
Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.
User | Count |
---|---|
143 | |
85 | |
66 | |
51 | |
45 |
User | Count |
---|---|
216 | |
89 | |
82 | |
66 | |
57 |