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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
HUEyoung
New Member

how can i edit table?

i have json similar this

 

1

{

      participants : [{name : 'aa', email : 'bb'}]

}

2

{

      participants : [{name : 'ac', email : 'bd'}, {name: 'bg', email : 'ch'}]

}

3

{

      participants : [{name : 'ai', email : 'bi'}, {name: 'kb', email : 'ci'},{name : 'av', email : 'bd'}]

}

 

i cant find excel import json multi select, so im add each json file.

 

{name,email} count is not determined. can i use for loop ? like for(i=0;i<participants[i].length; i++) ?

 

currently, it shows

 

participants.name          participants.email              another key

aa                                   bb                                         1

ac                                   bd                                          2

bg                                   ch                                       2

ai                                  bi                                            3

kb                                   ci                                           3

av                                  bd                                          3

 

 

and i want insert excel like this

 

 

participants1.name     participants1.email   participants2.name     participants2.email    participants3.name    participants3.email

aa                                bb

ac                                bd                             bg                                   ch

ai                                 bi                               kb                                   ci                                   av                              bd

 

i need help

1 REPLY 1
wdx223_Daniel
Super User
Super User

say the column name is "participant", try this

=Table.TransformColumns(TableFromJson,{"participant",each let tbl=Table.Combine(List.Transform(_,Record.ToTable)),header=List.Accumulate(tbl[Name],{{},[]},(x,y)=>let r=Record.TransformFields(x{1},{y,each _+1??1},2) in {x{0}&{"participant"&Text.From(Record.Field(r,y))&"."&y},r}){0} in #table(header,{tbl[Value]})})

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

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 Solution Authors