Skip to main content

Notifications

Power Automate - Using Connectors
Answered

Value and values data captured

(0) ShareShare
ReportReport
Posted on by 164

Hi Everyone,

 

I have an array and want to get the data from "Values", the scope in the original data is {[{[[ ]]}]} and I want to get the "Values" to be [[ ]], is there has a way to get this result, I tried below expression can't work:

body('XXXX')?['Value']?['Values']

body('XXXX')?['Value']?['items']

 

Original Array show as below:

{

    "@odata.context": "https://graph.microsoft.com/v1.0/$metadata#sites('XXXXXX-a485-3XX6XXXXXX0XX09tafd0-XXXXX-466-XXX70-5bXXXXX1')/lists('XXXX-cc58-XXXX-XXXXX4b')/drive/items('0XXXXXXXX6JWXXXXXXLRXXXXXL')/workbook/tables('table1')/rows",

    "value": [

        {

            "@odata.id": "/sites('XXXXXXXXXX-3b1-4e61-XXX-38e67de76b90%XXXafd0-7869-466-9b70-XXXXXXXXXXX')/lists('XXXXXXXX-XXXXXX1Xb')/drive/items('05XAKKXXXXXXXXXFQ6XXXX7TK')/workbook/tables(%8XXXX-4F3-BBAC-9XXX9XXXXXX%7D%7)/rows/itemAt(index=0)",

            "index": 0,

            "values": [

                [

                    4378,

                    43780,

                    "",

                    "",                   

                    "",

                    4373,

                    "K/B"

                ]

            ]

        }

    ]

}

 

Final, I want the array to be displayed as below:

[

  [

     4378,

     43780,

     "",

     "",                   

     "",

   4373,

   "K/B"

  ]

]

Can anyone have a suggestion? Thank you very much.

 

Regards,

ilu989

 

 

  • ilu989 Profile Picture
    ilu989 164 on at
    Re: Value and values data captured

     Hi @v-alzhan-msft 

     

    Finally, I find a way to approach what I need, use "Select" to treat outputs and set the expression for example as below:

    Thanks for your guide to let me finish this!!

    {

      "0": @{item()?['values'][0][0]},

      "1": @{item()?['values'][0][1]},

      "2": @{item()?['values'][0][2]},

      "3": @{item()?['values'][0][3]}

    }

    values.value.png

     

    The output will display be:

     

    value1.JPG

     

    Regards,

    ilu989

  • ilu989 Profile Picture
    ilu989 164 on at
    Re: Value and values data captured

     Hi @v-alzhan-msft ,

     

    Finally, I find a way to approach what I need, use "Select" to treat outputs and set the expression for example as below:

    Thanks for your guide to let me finish this!!

    {

      "0": @{item()?['values'][0][0]},

      "1": @{item()?['values'][0][1]},

      "2": @{item()?['values'][0][2]},

      "3": @{item()?['values'][0][3]}

    }

    values.value.png

     

    The output will display be:

     

    value1.JPG

     

    Regards,

    ilu989

  • ilu989 Profile Picture
    ilu989 164 on at
    Re: Value and values data captured

    Hi @v-alzhan-msft ,

     

    Thanks for your response, because the array is created by the Flow's step automatically, so I can't remove the character "@"

    Below are my Flow's outputs, is there has some expression can avoid the head of @?

    value.JPG

     

    Regards,

    ilu989

     

  • Verified answer
    Re: Value and values data captured

    Hi @ilu989 ,

     

    Please take a try with expression below:

    body('XXXX')?['value'][0]['values']

    I have made a test on my side and could I'm couldn't create an object for the data that you provided:

    1.png

    If I remove the @ symbol from the data,then you could refer to screenshot to create the flow:

    2.png

     

    The expression in the Compose as below:

    variables('test')?['value'][0]['values']

    The flow would run successfully as below:

    3.png

     

    Best regards,

    Alice       

     

    Community Support Team _ Alice Zhang
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

     

     

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

Microsoft Kickstarter Events…

Register for Microsoft Kickstarter Events…

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Announcing Forum Attachment Improvements!

We're excited to announce that attachments for replies in forums and improved…

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 145,343

#2
RandyHayes Profile Picture

RandyHayes 76,287

#3
Pstork1 Profile Picture

Pstork1 64,703

Leaderboard

Featured topics