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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
EaglesTony
Post Prodigy
Post Prodigy

How can I get a table to collapse so certain columns only appear when they change

I have the following table:

 

AREA        DOMAIN    SUBDOMAIN     TEACHER    ASSISTANT

1               1                 1                        Joe             Karen

1               1                 2                       Frank          Tom

1               2                 7                       Mia             Bobby

2               3                 4                       Lori             Karen

2               3                 5                       Mia             Frank

2               4                 9                       Mary          Adam

 

I'm trying to get it so AREA/DOMAIN/SUBDOMAIN dont repeat so it looks like:

AREA        DOMAIN    SUBDOMAIN     TEACHER    ASSISTANT

1               1                 1                        Joe             Karen

                                    2                       Frank          Tom

1               2                 7                       Mia             Bobby

2               3                 4                       Lori             Karen

                                    5                       Mia             Frank

                 4                 9                       Mary          Adam

 

 

26 REPLIES 26
MasonMA
Impactful Individual
Impactful Individual

@EaglesTony then reshaping them in Power Query is the right solution, isnt it? btw you may need to use table in reporting. 

I can group them in PowerQuery, but it repeats the Domain and SubDomain.

MasonMA
Impactful Individual
Impactful Individual

@EaglesTony 

Can you show me your Grouped results and be more specific on how these two are repeating? 

I group by Area,Domain,SubDodomain and it does the grouping correctly, but the results are:

 

AREA        DOMAIN    SUBDOMAIN     TEACHER    ASSISTANT

1               1                 1                        Joe             Karen

1               1                 2                       Frank          Tom

1               2                 7                       Mia             Bobby

2               3                 4                       Lori             Karen

2               3                 5                       Mia             Frank

2               4                 9                       Mary          Adam

 

So the first 3 columns solves the group, but the 3 columns mentioned are repeated, so it should show the first time those columns, but next one that is similiar, leave that blank.

 

What I am wondering is if I can somehow have another column such as 

AREA        DOMAIN    SUBDOMAIN     TEACHER    ASSISTANT   LEVEL

1               1                 1                        Joe             Karen             1

1               1                 2                       Frank          Tom                2

1               2                 7                       Mia             Bobby            1 

2               3                 4                       Lori             Karen             1 

2               3                 5                       Mia             Frank             2

2               4                 9                       Mary          Adam             1

 

Then do some logic if not level 1, replace the column value with blank.

MasonMA
Impactful Individual
Impactful Individual

@EaglesTony 

Did you try the initial approach i offered step by step in this thread? 

You would need to add 3 separate Custom columns for 'AREA, 'DOMAIN', 'SUBDOMAIN' each to make repeating rows null by M coding. 

They are blank when duplicated

 

image.png

 

If this helped, please consider giving kudos and mark as a solution

@me in replies or I'll lose your thread

consider voting this Power BI idea

Francesco Bergamaschi

MBA, M.Eng, M.Econ, Professor of BI

Helpful resources

Announcements
July PBI25 Carousel

Power BI Monthly Update - July 2025

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

Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 community update carousel

Fabric Community Update - June 2025

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