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

Community site session details

Session Id : HvNWYLzFy7q+e1Tvbyh8u9
Power Automate - General Discussion
Answered

Update row in Excel using dynamic content is not adding fields into row

Like (0) ShareShare
ReportReport
Posted on 20 Jul 2023 05:36:46 by 62

Hi 

I am running a flow where I am extracting data and adding rows into an excel table.  I am then taking a key field from my extract and using this field into a PowerBI query to return two other variables which I want to then update the row in excel that I have just added.

the query returns the correct data and I map it to a variable using the select statement - but when I go to update the row in excel it does not update - it 

 

perksyaus_0-1689826530982.png

perksyaus_1-1689831359006.png

I'm not sure what I am doing worng.

 

Denise

I have the same question (0)
  • perksyaus Profile Picture
    62 on 21 Jul 2023 at 05:06:16
    Re: Update row in Excel using dynamic content is not adding fields into row

    When I first put your code in it did not like it - but today it does - thanks so much this is perfect

  • Verified answer
    ManishSolanki Profile Picture
    15,087 Super User 2025 Season 2 on 21 Jul 2023 at 04:53:14
    Re: Update row in Excel using dynamic content is not adding fields into row

    Hi Denise,

     

    You need to write an expression to get the value of 'ProfitCentre' property from the output array of Select action.

     

    Here are the detailed steps to extract the value from Select action output:

    ManishSolanki_0-1689914807352.png

    1. Click & select the column to update in the excel, here I have chosen Serial# column to update.

    2. Next, we will select 'Expression' option and type the below expression in the expression textbox. First() formula will get the first item of an array and then we will pull out 'ProfitCenter' value using indexer:

    first(body('Select'))?['ProfitCenter']

    3. Click, save & test your flow

     

    If this helps & solves your problem, please remember to give a 👍 and accept my solution as it will help others in the future.

     

    Thanks

  • perksyaus Profile Picture
    62 on 20 Jul 2023 at 23:53:18
    Re: Update row in Excel using dynamic content is not adding fields into row

    Thanks for the reply:  the output from the select returns as an array:

     

    [
      {
        "Material": "1557LV",
        "ProfitCentre": "1TR007LV00"
      }
    ]
     
    I just require the value to be updated in the Excel row - but I can't get the syntax right to access the value in the array - any help would be grateful
    Denise
  • wskinnermctc Profile Picture
    6,519 Moderator on 20 Jul 2023 at 16:07:53
    Re: Update row in Excel using dynamic content is not adding fields into row

    You are using the Variable in multiple steps, but that doesn't change the variable. You could use the Variable in 10 different steps and it will remain the same, that is the purpose of using a variable. 

    You set a Variable to be a value, and then when you use the Variable throughout the flow, it will remain that same value.


    The only way to change a Variable is to use another Set Variable action or Append to Variable action. 

  • ManishSolanki Profile Picture
    15,087 Super User 2025 Season 2 on 20 Jul 2023 at 07:18:16
    Re: Update row in Excel using dynamic content is not adding fields into row

    Hi @perksyaus 

     

    You can get the value of 'Profit Center' without using variable. For that, you don't need to write the variable name in Map key inside select action, just type the plain text 'ProfitCenter' as shown beloe:

    ManishSolanki_0-1689837428397.png

     

    Once it is done, then you can write the below expression in the Update row action to save that value in excel sheet:

    first(body('Select'))?['ProfitCenter']

     

    If this helps & solves your problem, please remember to give a 👍 and accept my solution as it will help others in the future.

     

    Thanks

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Telen Wang – Community Spotlight

We are honored to recognize Telen Wang as our August 2025 Community…

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Tomac Profile Picture

Tomac 986 Moderator

#2
stampcoin Profile Picture

stampcoin 699 Super User 2025 Season 2

#3
Riyaz_riz11 Profile Picture

Riyaz_riz11 577 Super User 2025 Season 2

Loading started