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

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

Reply
calculateadvers
Frequent Visitor

Dynamically expand tables in columns

In the example below, how would I add a step to go through the "condition" column and expand Tables? I would want Row 9 to expand into two rows, where one has [condition] as "Cardiovascular Diseases" and one as "Coronary Disease". Then I should have a total of 10 Rows.

calculateadvers_1-1608233932406.png

 

 

1 ACCEPTED SOLUTION
Fowmy
Super User
Super User

@calculateadvers 

One quick way to do it is to duplicate your query, filter the condition column to Table  and click onthe column header to expand into two rows. 

Filter out the rows with Table in the original query and append with the duplicated query.

________________________

If my answer was helpful, please click Accept it as the solution to help other members find it useful

Click on the Thumbs-Up icon if you like this reply 🙂


Website YouTube  LinkedIn
 

Did I answer your question? Mark my post as a solution! and hit thumbs up


Subscribe and learn Power BI from these videos

Website LinkedIn PBI User Group

View solution in original post

3 REPLIES 3
CNENFRNL
Community Champion
Community Champion

@calculateadvers , you might want to uncheck all those undesired options in the dropdown list

Untitled.png

or use M code to sort out more specifically options you need.

let
    Source = #table({"id","options"},{{"id1",1},{"id2",#table({"col"},{{"x"}})},{"id3",{100,2}},{"id4","zyx"},{"id5",{}}}),

    #"Filtered Rows" = Table.SelectRows(Source, each Value.Is([options], List.Type) and [id]="id5")

in
    #"Filtered Rows"

Thanks to the great efforts by MS engineers to simplify syntax of DAX! Most beginners are SUCCESSFULLY MISLED to think that they could easily master DAX; but it turns out that the intricacy of the most frequently used RANKX() is still way beyond their comprehension!

DAX is simple, but NOT EASY!

Fowmy
Super User
Super User

@calculateadvers 

One quick way to do it is to duplicate your query, filter the condition column to Table  and click onthe column header to expand into two rows. 

Filter out the rows with Table in the original query and append with the duplicated query.

________________________

If my answer was helpful, please click Accept it as the solution to help other members find it useful

Click on the Thumbs-Up icon if you like this reply 🙂


Website YouTube  LinkedIn
 

Did I answer your question? Mark my post as a solution! and hit thumbs up


Subscribe and learn Power BI from these videos

Website LinkedIn PBI User Group

Thanks @Fowmy .

 

I considered that as an option, but I ran into a roadblock trying to figure out how to filter a column to show only Table or non-Table.

 

In the Power Query Interface for the filter dropdown, Table  does not appear as one of the options for filtering. Only the text in rows that are not Table display.

 

How do I filter only to show rows where [condition] is Table ?

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

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.

Top Kudoed Authors