title: Extract elements from array and then update their fields using Logic Apps
body: <p>I wish to grab the elements in the Feedbacks array and then update two fields within that ids array:</p>
  <p> </p>
  <pre><code>&quot;Feedbacks&quot;: 
  
    [
  
       {
  
       &quot;ids&quot;: &quot;1234&quot;
  
       }
  
      {
  
      &quot;ids&quot;: &quot;4567&quot;
  
      }
  ]
  </code></pre>
  <p>update this</p>
  <pre><code>&quot;id&quot;:&quot;1234&quot;
  &quot;Features&quot;:
  
   [
  
  {
    &quot;id&quot;: &quot;change this&quot;
    &quot;status&quot;: &quot;change this&quot;
  }
  
   ]
  
  
  &quot;id&quot;: &quot;4567&quot;
  &quot;Features&quot;:  
  
     [
          
    {
  
      &quot;id&quot;: &quot;change this&quot;
      &quot;status&quot;: &quot;change this&quot;
  
    }
  ]
  </code></pre>
  <p>I believe I may have to do this, does this look correct please, is this the correct approach?</p>
  <p>Create two local variables that will update status and id.</p>
  <p>I am seeing that I cannot dynamically put in the 'FeatureID' on variable 2 though because it is globally above the CDS step.</p>
  <p><a href="https://i.stack.imgur.com/iiGzt.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/iiGzt.png" alt="enter image description here" /></a>
  <a href="https://i.stack.imgur.com/otF82.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/otF82.png" alt="enter image description here" /></a></p>
  <p>Any suggestion is appreciated. Thank you</p>
  <pre><code>   JSON ORIGINAL DATA THAT HOLDS FEEDBACK ARRAY IN BOLD
   {
    &quot;Blocking&quot;: &quot;test&quot;,
    &quot;CRMLink&quot;: null,
    &quot;Contact&quot;: &quot;test&quot;,
    &quot;CreatedBy&quot;: null,
    &quot;DomainOwnerPriority&quot;: null,
    &quot;FeatureCategory&quot;: &quot;test&quot;,
    &quot;FeatureCreatedOnDate&quot;: null,
    &quot;FeatureId&quot;: &quot;test&quot;,
    &quot;FeaturePM&quot;: &quot;test&quot;,
    &quot;FeatureTitle&quot;: &quot;test&quot;,
    &quot;FeedbackDescription&quot;: &quot;test&quot;,
    &quot;FeedbackName&quot;: &quot;test&quot;,
    &quot;FeedbackSource&quot;: &quot;test&quot;,
    &quot;FeedbackSourceLink&quot;: &quot;test&quot;,
    &quot;FeedbackSubmittedBy&quot;: &quot;test&quot;,
    &quot;FeedbackType&quot;: &quot;test&quot;,
    *&quot;Feedbacks&quot;: [
                         {
                          &quot;id&quot;:&quot;1234&quot;
                         }
                   ],*
    &quot;GPM&quot;: null,
  
   }
  </code></pre>
  <p>JSON ORIGINAL DATA THAT HOLDS FEATURES ARRAY</p>
  <pre><code> {
    &quot;id&quot;: &quot;123&quot;,
    &quot;feedback&quot;: {
    &quot;Blocking&quot;: &quot;&quot;,
    &quot;CContact&quot;: &quot;&quot;,
    &quot;Competition_Details&quot;: &quot;&quot;,
    &quot;Count_Of_Comments&quot;: &quot;0&quot;,
    &quot;Count_Of_Votes&quot;: 0,
    &quot;Domain_Area&quot;: &quot;&quot;,
    **&quot;Features&quot;: [**
        {
          **&quot;id&quot;: &quot;something&quot;,
          &quot;state&quot;: &quot;something&quot;**
        }
      ],
     &quot;Feedback_CreatedOn_Date&quot;: &quot;test&quot;,
     &quot;Feedback_Description&quot;: &quot;text&quot;,
     &quot;Feedback_EnteredIn_Amalgam_Date&quot;: &quot;test&quot;,
     &quot;Feedback_Name&quot;: &quot;test&quot;,
     &quot;Feedback_Source&quot;: &quot;test&quot;,
     &quot;Feedback_Source_ID&quot;: &quot;test&quot;,
     &quot;Feedback_Source_Link&quot;: &quot;test&quot;,
     &quot;Feedback_Submitted_By&quot;: &quot;test&quot;,
  
  }
  </code></pre>
  <p>Hi, I am trying to access the Feedback array which hold these ids. Once I loop over each id, (ex. 1234) I need to change the Features array within the 'ids' and update the id and status.
  I think the correct approach is to create a variable, do a for each loop and do an update. I am just not sure and would appreciate any advice</p>