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!Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
Hi All
Below is a sample table for which a pivot needs to be created.
Measure:
Err = IF(HASONEVALUE(Range[Group2]),0.11,IF(HASONEVALUE(Range[Group1]),0.03,0.02))
The goal is to create Err as expected but it fails when context for Group1/Group2 gets filtered down to one value. Please fish me out of this problem I've been struggling with from past two days. Thanks in advance.
Thanks
Guru
Solved! Go to Solution.
@Anonymous , Try with isinscope
Measure:
Err = IF(isinscope(Range[Group2]),0.11,IF(isinscope(Range[Group1]),0.03,0.02))
https://www.kasperonbi.com/use-isinscope-to-get-the-right-hierarchy-level-in-dax/
Hi, @Anonymous
Please try the below measure.
Hi, My name is Jihwan Kim.
If this post helps, then please consider accept it as the solution to help other members find it faster.
Hi, @Anonymous
Please try the below measure.
Hi, My name is Jihwan Kim.
If this post helps, then please consider accept it as the solution to help other members find it faster.
Amazing!! I've been struggling from past two days and you all solved it like nothing. Is it possible to accept multiple answers as solutions? Have come to know that ISFILTERED can result in false positives hence accepting the reply from @amitchandak as the solution. Hope you understand. Thanks by the way for your quick response.
@Anonymous , Try with isinscope
Measure:
Err = IF(isinscope(Range[Group2]),0.11,IF(isinscope(Range[Group1]),0.03,0.02))
https://www.kasperonbi.com/use-isinscope-to-get-the-right-hierarchy-level-in-dax/
You really are a super man. Have searched lot of questions and most of them had your replies. And thanks a lot for the best possible solution. Somehow I'm unable to see ISINSCOPE while creating DAX measure.
Check out the November 2025 Power BI update to learn about new features.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
| User | Count |
|---|---|
| 103 | |
| 80 | |
| 62 | |
| 50 | |
| 45 |