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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
Thulasiram
Helper II
Helper II

How to create an additional column of text

Dear all,

 I have created a Matrix conaining Top N suppliers.

I have created a measure to get the top n.

I wish to create a new column in the matrix wherein I will put

some random remarks against each supplier with a measure.

Need help.  Thanks and appreciate.

1 ACCEPTED SOLUTION
rajendraongole1
Super User
Super User

Hi @Thulasiram - Create below measure with your main kpi and add text details like remarks for each supplier in a matrix in Power BI using a measure.

 

TopNSupplierRemarks =
IF(
    RANKX(ALL('financials'), [profittotal], , DESC) <= 2,  -- Change 5 to your Top N count
    SWITCH(
        TRUE(),
        SELECTEDVALUE('Financials'[Product]) = "Product A", "Remark for Product A",
        SELECTEDVALUE('Financials'[Product]) = "Product B", "Remark for Product B",
        SELECTEDVALUE('Financials'[Product]) = "Product C", "Remark for Supplier C",
        "Default Remark"
    ),
    BLANK()
)
 

 

rajendraongole1_0-1718785468932.png

 

I have defined rank with 2 , you can change the count as per your requirement.

 

 

Did I answer your question? Mark my post as a solution! This will help others on the forum!
Appreciate your Kudos!!





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!





View solution in original post

4 REPLIES 4
Thulasiram
Helper II
Helper II

Thank you very much @rajendraongole1 .

It solved my problem.  Thanks for taking time in giving the dax code which was very helpful.

rajendraongole1
Super User
Super User

Hi @Thulasiram - Create below measure with your main kpi and add text details like remarks for each supplier in a matrix in Power BI using a measure.

 

TopNSupplierRemarks =
IF(
    RANKX(ALL('financials'), [profittotal], , DESC) <= 2,  -- Change 5 to your Top N count
    SWITCH(
        TRUE(),
        SELECTEDVALUE('Financials'[Product]) = "Product A", "Remark for Product A",
        SELECTEDVALUE('Financials'[Product]) = "Product B", "Remark for Product B",
        SELECTEDVALUE('Financials'[Product]) = "Product C", "Remark for Supplier C",
        "Default Remark"
    ),
    BLANK()
)
 

 

rajendraongole1_0-1718785468932.png

 

I have defined rank with 2 , you can change the count as per your requirement.

 

 

Did I answer your question? Mark my post as a solution! This will help others on the forum!
Appreciate your Kudos!!





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!





PijushRoy
Super User
Super User

Hi @Thulasiram 

Please use RANKX for define topn customer https://databear.com/how-to-use-the-dax-rankx-function-in-power-bi/ and then define rank wise note in measure with SWITCH statement




Did I answer your question? Mark my post as a solution!
Appreciate your Like/Kudos

Proud to be a Super User!





Thank you @PijushRoy 

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

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

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.