cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
NewBee117
Kudo Collector
Kudo Collector

Expression nesting too deep. An expression in your formula is nested more than 50 levels.

My Powerapps put a table in JSON format, run a flow to export it as an Excel file, then return the file link saved in One Drive. When the table has four columns, it runs fine. However, when the table has 16 columns, I get an error in the app saying "Expression nesting too deep. An expression in your formula is nested more than 50 levels.". How do I get around this?

 

NewBee117_0-1620218160787.png

The flow runs fine with the same output to Powerapps (4 or 16 columns):

NewBee117_1-1620218295707.png

 

 

 

1 ACCEPTED SOLUTION

Accepted Solutions

Use the expression editor and that compose value will be something like:

['Parse__JSON']?[All_0x00_OnsiteRESTOFNAMEHERE]

Now its an object with a property of Value, so I think we can use:

['Parse__JSON']?[All_0x00_OnsiteRESTOFNAMEHERE]?[Value]

@iAm_ManCat


Please 'Mark as Solution' if someone's post answered your question and always 'Thumbs Up' the posts you like or that helped you!


Thanks!
You and everyone else in the community make it the awesome and welcoming place it is, keep your questions coming and make sure to 'like' anything that makes you 'Appy
Sancho Harker, MVP


View solution in original post

6 REPLIES 6
iAm_ManCat
Super User
Super User

Hi,

 

Try using the JSON() function to convert the data to JSON instead of setting it all manually as a giant text string, this might help with reducing the formula engine overhead. Without seeing the rest of your code its hard to say where the nesting error is,

 

Cheers,

@iAm_ManCat


Please 'Mark as Solution' if someone's post answered your question and always 'Thumbs Up' the posts you like or that helped you!


Thanks!
You and everyone else in the community make it the awesome and welcoming place it is, keep your questions coming and make sure to 'like' anything that makes you 'Appy
Sancho Harker, MVP


NewBee117
Kudo Collector
Kudo Collector

I started with JSON(). My data source is a SharePoint list with dropdown control. The JSON() function does not see those columns. The ShowColumns function does not see those columns either. 

NewBee117
Kudo Collector
Kudo Collector

Update, I am able to pull the SharePoint list columns, but JSON() returns more than just the actual value of the field. How do I modify the JSON file to show only value, and also, how to update the column header? Thanks.

 

NewBee117_0-1620253347881.png

 

This will depend on how you are exporting those values - what did you do with the JSON function and how does your flow treat that data?

 

I've been thinking about this and I think I would probably do this a different way and get the IDs for each row you are exporting to excel and then have flow use the Get Item for each ID row and then construct your excel file that way by appending it to a string array..

@iAm_ManCat


Please 'Mark as Solution' if someone's post answered your question and always 'Thumbs Up' the posts you like or that helped you!


Thanks!
You and everyone else in the community make it the awesome and welcoming place it is, keep your questions coming and make sure to 'like' anything that makes you 'Appy
Sancho Harker, MVP


NewBee117
Kudo Collector
Kudo Collector

Here is the flow (not working):

    NewBee117_1-1620316329394.png

And here is the JSON schema used in the step for Parse JSON:

     NewBee117_3-1620319318724.png

Value for fields like Title shows up correctly in "Select", what can I do to pull value from the ones with type "object"?

    NewBee117_4-1620319726128.png

 

 

 

 

 

 

 

 

 

Use the expression editor and that compose value will be something like:

['Parse__JSON']?[All_0x00_OnsiteRESTOFNAMEHERE]

Now its an object with a property of Value, so I think we can use:

['Parse__JSON']?[All_0x00_OnsiteRESTOFNAMEHERE]?[Value]

@iAm_ManCat


Please 'Mark as Solution' if someone's post answered your question and always 'Thumbs Up' the posts you like or that helped you!


Thanks!
You and everyone else in the community make it the awesome and welcoming place it is, keep your questions coming and make sure to 'like' anything that makes you 'Appy
Sancho Harker, MVP


Helpful resources

Announcements
PA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

This training provides practical hands-on experience in creating Power Apps solutions in a full-day of instructor-led App creation workshop.

Microsoft Build 768x460.png

Microsoft Build is May 24-26. Have you registered yet?

Come together to explore latest innovations in code and application development—and gain insights from experts from around the world.

May UG Leader Call Carousel 768x460.png

What difference can a User Group make for you?

At the monthly call, connect with other leaders and find out how community makes your experience even better.

Top Solution Authors
Top Kudoed Authors
Users online (2,220)