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 / ParseJSON does not all...
Power Apps
Answered

ParseJSON does not allow numbers as "items"

(0) ShareShare
ReportReport
Posted on by 29

Hi,

I recently switch from using Power Automate Parse JSON action to Power Apps ParseJSON (preview) to later on compose array because for flow it took too long for the end user.

When I tried to do so by following documentation I have got an error which I'm reporting because it may be an easy fix.

 

Bullet points:

1. JSON to be parsed stored in JsonString_1 control (TextInput):

 

{

 "Data": [

 {

 "MATCH": {

 "0": {

 "TEXT": "ABC",

 "SCORE": 1

 }

 }

 }

 ]

}

 

2. This is external response so it is as it is - not possible to change (I modified it to reflect only necessary part)

3. As you see this is nested, but even tho it should be easily possible to extract. 

4. "0":{ part cause the problem

5. Formula which should work but IS NOT WORKING:

 

ForAll(
 Table(
 ParseJSON( 
 JsonString_1.Text
 ).Data
 )
 ,{
 TEXT: Text(
 ThisRecord.Value.MATCH.0.TEXT
 )
 ,SCORE: Value(
 ThisRecord.Value.MATCH.0.SCORE
 )
 }
)

 

 6. In order for this to work I need to use Substitute function to replace "0":{ with anything else than number - in my case it is "ALL":{

7. It is not possible to hardcode ""0":{" in Substitute function because of misinterpretation of " so I need to call datasource (Dataverse in my case) to retrieve both old text and new text for Substitute function.

8. After Substitution JSON look like below

 

 

{

 "Data": [

 {

 "MATCH": {

 "ALL": {

 "TEXT": "ABC",

 "SCORE": 1

 }

 }

 }

 ]

}

 

 

9. And ParseJSON code which IS WORKING look like below

 

ForAll(
 Table(
 ParseJSON( 
 JsonString_1.Text
 ).Data
 )
 ,{
 TEXT: Text(
 ThisRecord.Value.MATCH.ALL.TEXT
 )
 ,SCORE: Value(
 ThisRecord.Value.MATCH.ALL.SCORE
 )
 }
)

 

 10. In my case I'm pretty sure that zero in this part: "0":{ caused error.

 

I hope I was clear enough to explain this error - if not feel free to reach out to me for more details 🙂

It would be great not to be forced to use such a way around because it may not be so obvious for everyone.

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

    put the quotes in single quotes: ParseJSON(....).Data.Match.'0'

  • Tomasz Pagacz Profile Picture
    29 on at

    I tried with ", should tried also with '.

    Easier than I thought 🙂

    Thanks for explanation.

    Below few related links from your response to Idea of ParseJSON.

    Parse JSON in PowerApps - Power Platform Community (microsoft.com)

     

    See the announcement here:

    https://powerapps.microsoft.com/en-us/blog/power-fx-introducing-parsejson/

     

    Documentation can be found here:

    https://docs.microsoft.com/power-platform/power-fx/working-with-json

    https://docs.microsoft.com/power-platform/power-fx/reference/function-parsejson

    https://docs.microsoft.com/power-platform/power-fx/untyped-object

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 529 Most Valuable Professional

#2
Haque Profile Picture

Haque 230

#3
Kalathiya Profile Picture

Kalathiya 217 Super User 2026 Season 1

Last 30 days Overall leaderboard