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

Score big with last-minute savings on the final tickets to FabCon Vienna. Secure your discount

Reply
jay_patel
Helper IV
Helper IV

In matrix visual , instead of all measures in values section , add only desired measures in column

In matrix visual , when we specify "column" and some measures in "Values" section , then it considers all measures under column . Instead I want only desired measures to work as per column context and other measures should work as it is .

Below image in yellow highlight is the desired output.

fgfg

Measures "Total drs met" and "Total calls" should only work under column section. "Gyne","Ortho","Phy" are values of column spec desc.

The other 3 measures should work as it is.

 

Currently, it shows as per below image: (all the measures under column section)

Capture2.PNG

@amitchandak 

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @jay_patel 

 

You can first refer to the following blogs to learn about how to create a hybrid matrix. 

Creating a “custom” or “hybrid” matrix in PowerBI - Microsoft Fabric Community

Advanced 2-Dimensional Table Transformation with DAX | Medium

 

As the examples in above blogs have only one column level, I create a simple demo which has two column levels as below:

vjingzhanmsft_0-1709794772862.png

I have a table like below for the column headers. 

vjingzhanmsft_1-1709794823101.png

And you have to create a complex measure to feed the Values section. Here is an example:

Hybrid Measure = 
IF (
    ISINSCOPE ( 'Table'[Child Metrics] ),
    SWITCH (
        SELECTEDVALUE ( 'Table'[Child Metrics] ),
        "Total Drs", CALCULATE([Total Drs],'Actual Table'[Spec Desc]=SELECTEDVALUE('Table'[Metrics])),
        "Total Calls", CALCULATE([Total Calls],'Actual Table'[Spec Desc]=SELECTEDVALUE('Table'[Metrics])),
        "",
            SWITCH (
                SELECTEDVALUE ( 'Table'[Metrics] ),
                "Total Doctors Met", [Total Doctors Met],
                "Total Doctors Planned", [Total Doctors Planned]
            )
    )
)

 

You will have to modify the table and measure according to your model. 

 

Best Regards,
Jing
If this post helps, please Accept it as Solution to help other members find it. Appreciate your Kudos!

View solution in original post

1 REPLY 1
Anonymous
Not applicable

Hi @jay_patel 

 

You can first refer to the following blogs to learn about how to create a hybrid matrix. 

Creating a “custom” or “hybrid” matrix in PowerBI - Microsoft Fabric Community

Advanced 2-Dimensional Table Transformation with DAX | Medium

 

As the examples in above blogs have only one column level, I create a simple demo which has two column levels as below:

vjingzhanmsft_0-1709794772862.png

I have a table like below for the column headers. 

vjingzhanmsft_1-1709794823101.png

And you have to create a complex measure to feed the Values section. Here is an example:

Hybrid Measure = 
IF (
    ISINSCOPE ( 'Table'[Child Metrics] ),
    SWITCH (
        SELECTEDVALUE ( 'Table'[Child Metrics] ),
        "Total Drs", CALCULATE([Total Drs],'Actual Table'[Spec Desc]=SELECTEDVALUE('Table'[Metrics])),
        "Total Calls", CALCULATE([Total Calls],'Actual Table'[Spec Desc]=SELECTEDVALUE('Table'[Metrics])),
        "",
            SWITCH (
                SELECTEDVALUE ( 'Table'[Metrics] ),
                "Total Doctors Met", [Total Doctors Met],
                "Total Doctors Planned", [Total Doctors Planned]
            )
    )
)

 

You will have to modify the table and measure according to your model. 

 

Best Regards,
Jing
If this post helps, please Accept it as Solution to help other members find it. Appreciate your Kudos!

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.