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
RPeruski
Frequent Visitor

How to Expand a List within a column where there are both Lists and Text

I have some data that I extracted from a JSON which loaded my data into a single column with some of the data being text and some of the data being lists within the same column. Typically when a column has lists the drop down at the column header has the icons to expand the column, because the list contains both text & list values, the drop down button only lets me filter to the text values. 

 

Is there a method to either deliminate the list values within the single column or to break into new columns? For reference I've tried to split column by deliminater and that hasn't worked. 

1 ACCEPTED SOLUTION

Hi @RPeruski 

 

Try to add a new column with following code:

 

if Value.Is([Car Failures Reported Per Customer], type list) 
                then Text.Combine(List.Transform([Car Failures Reported Per Customer], Text.From), ",")
           else [Car Failures Reported Per Customer]

This will give you something similar to this:

 

MFelix_0-1746031271505.png


Then you can make split columns to rows based on the comma.


Regards

Miguel Félix


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

Proud to be a Super User!

Check out my blog: Power BI em Português



View solution in original post

6 REPLIES 6
MFelix
Super User
Super User

Hi @RPeruski ,

 

Since you have the column being a JSON you can do the parse as JSON in the Power Query:

https://support.microsoft.com/en-us/office/parse-text-as-json-or-xml-power-query-7436916b-210a-4299-...


Regards

Miguel Félix


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

Proud to be a Super User!

Check out my blog: Power BI em Português



The column with list and text values is after I've parsed as JSON in Power Query and then expanded the values as new columns.

Can you please share a mockup data or sample of your PBIX file. You can use a onedrive, google drive, we transfer or similar link to upload your files.

If the information is sensitive please share it trough private message.


Regards

Miguel Félix


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

Proud to be a Super User!

Check out my blog: Power BI em Português



Here is a mock up of what the data looks like.

 

Car Failures Reported Per Customer

Engine

Transmission
List
Brakes

 

Then the List would contain the following 

Engine
Brakes

Hi @RPeruski 

 

Try to add a new column with following code:

 

if Value.Is([Car Failures Reported Per Customer], type list) 
                then Text.Combine(List.Transform([Car Failures Reported Per Customer], Text.From), ",")
           else [Car Failures Reported Per Customer]

This will give you something similar to this:

 

MFelix_0-1746031271505.png


Then you can make split columns to rows based on the comma.


Regards

Miguel Félix


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

Proud to be a Super User!

Check out my blog: Power BI em Português



Success! Thank you!

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.

Top Solution Authors