web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Make nested fields the...
Power Apps
Answered

Make nested fields their own columns in a data table

(0) ShareShare
ReportReport
Posted on by Microsoft Employee

I have a data table component populated by JSON from our API. Some fields are nested and I can't seem to get these nested fields to be recognized as their own column. When I try to edit the fields to add these, I only get the option to add "NestedField" as a whole as one column. So for example, we would get a response like such:

 

 

 

{
"Field1": "Value1",
"Field2": "Value2",
"NestedField": {
 "NestedField1" : "NestedValue1",
 "NestedField2" : "NestedValue2"
}
}

 

 

 

My table headers should be:

 

| Field1 | Field2 | NestedField1 | NestedField2 | .

 

I was thinking that I would need to use ClearCollect() to create the initial items for the table, and then use Collect() to go in, grab each nested value, and manually add it as a column. The closest I've gotten is adding these columns but they end up on their own row instead of included in their respective row. How can I accomplish this? Thanks!

Categories:
I have the same question (0)
  • Verified answer
    aec2018 Profile Picture
    Microsoft Employee on at

    I was able to figure it out from another comment in another post. I used the following formulas to create a new table with flattened data from my original table:

     

    ClearCollect(
     NewFlattenedTable,
     AddColumns(
     OldNestedTable,
     "NewColumn1",
     First(OldNestedTable).NestedField.NestedField1,
     "NewColumn2",
     First(OldNestedTable).NestedField.NestedField2
     )
    )

     

    Then I set the Items property of my data table to NewFlattenedTable and the columns were available to be added to the data table.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 366 Most Valuable Professional

#2
11manish Profile Picture

11manish 184

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 99 Super User 2026 Season 1

Last 30 days Overall leaderboard