Forum

Expand all columns ...
 
Notifications
Clear all

Expand all columns in power query (variable numer of columns)

2 Posts
2 Users
0 Reactions
231 Views
(@mihaipopescu)
Posts: 1
New Member
Topic starter
 

Hello,

I have a data model in power query that generates some kind of list of combinations.

I created to some point the model but I have a step that I don't know how to do.

I need to expand all the columns named from 1 to a total number of rows  (the number of columns is variable). rows are from the input table

Expand to new rows I need, yes it will be a really long list that is what I want

 

the file is attached.

Important1: expanding step by step is not acceptable because the number of columns will vary.

Important2: I am not a beginner please do not treat me like that.

 

I was thinking to make this with "try" and "otherwise" but I think there are better solutions. 

 

image

 
Posted : 08/11/2021 5:36 am
Philip Treacy
(@philipt)
Posts: 1629
Member Admin
 

Hi Mihai,

Transpose (Transform -> Transpose) the table then you have 1 column of lists and you can expand them all at once.

Regards

Phil

 
Posted : 08/11/2021 11:35 pm
Share: