Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Grow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.

Reply
Anonymous
Not applicable

Matrix - Different measure with different level of granularity

Hello everyone,

 

I have a matrix with different level of granularities:

  • Contract 1: XXXXX
    • Project 1.1: XXXXX/ABC
    • Project 1.2: XXXXX/DEF
    • ...
    • Project 1.6
      • Risk 1
      • Risk 2
      • Risk 3
  • Contract 2: YYYYY
    • Project 2.1: YYYYY/ABC
      • Risk 1
      • Risk 2
      • ...

I want to put a measure in column, but the measure should do different calculations at Contract level (sum the related projects) and project level (find a value in a related table), and return nothing at Risk level.

 

Any hint? I have tried with HASONEVALUE for risks, IF(HASONEVALUE(RiskNumber), "", IF(HASONEVALUE(Contract), SUM(...)...

 

But I have Project with only 1 risk, which then makes the related project and contract to have also "" 

 

If you have any ideas to get me started on the right path.

 

Thank you for your time,

Tom

1 ACCEPTED SOLUTION
v-lili6-msft
Community Support
Community Support

hi  @Anonymous 

You could get it by use ISINSCOPE Function to create a IF measure, see more detail as below:

https://xxlbi.com/blog/new-dax-function-isinscope/

 

Regards,

Lin

Community Support Team _ Lin
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

1 REPLY 1
v-lili6-msft
Community Support
Community Support

hi  @Anonymous 

You could get it by use ISINSCOPE Function to create a IF measure, see more detail as below:

https://xxlbi.com/blog/new-dax-function-isinscope/

 

Regards,

Lin

Community Support Team _ Lin
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

MayPowerBICarousel1

Power BI Monthly Update - May 2024

Check out the May 2024 Power BI update to learn about new features.