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

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
Anonymous
Not applicable

Table of all possible combinations

Hi, 

 

I have a list of 4 business units (BU) and I want to give each BU an score, A, B, C depending on some given criteria.  In below list there are 8 combinations, on rows 1-3 each BU gets the same score and on rows 5-8 there are some combinations with only A and B scores. How can I get a table of each possible combination?

 

#BU1BU2BU3BU4
1AAAA
2BBBB
3CCCC
4ABAA
5AABA
6AAAB
7ABBA
8ABBB

...and so on...

 

Best regards,

 

Chris

1 ACCEPTED SOLUTION
Greg_Deckler
Community Champion
Community Champion

@Anonymous I think maybe this:

Table = 
    GENERATEALL(
        GENERATEALL(
            SELECTCOLUMNS({ "A", "B", "C" },"Value1",[Value]),
            SELECTCOLUMNS({ "A", "B", "C" },"Value2",[Value])
        ),
        GENERATEALL(
            SELECTCOLUMNS({ "A", "B", "C" },"Value3",[Value]),
            SELECTCOLUMNS({ "A", "B", "C" },"Value4",[Value])
        )
    )


Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

View solution in original post

2 REPLIES 2
Greg_Deckler
Community Champion
Community Champion

@Anonymous I think maybe this:

Table = 
    GENERATEALL(
        GENERATEALL(
            SELECTCOLUMNS({ "A", "B", "C" },"Value1",[Value]),
            SELECTCOLUMNS({ "A", "B", "C" },"Value2",[Value])
        ),
        GENERATEALL(
            SELECTCOLUMNS({ "A", "B", "C" },"Value3",[Value]),
            SELECTCOLUMNS({ "A", "B", "C" },"Value4",[Value])
        )
    )


Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...
Anonymous
Not applicable

Hi, @Greg_Deckler , thanks a lot, this works perfect.

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.