How to Update a SharePoint List Item from another SharePoint List Using Power Automate?

While working on a leave request application, I needed to update a SharePoint list item from another SharePoint list using Power Automate. There are two different SharePoint lists. Such as:

  1. Employee Leave Balance Management: Here, the HR team updates the leave balances of each employee.
  2. Employee Leave Balance Details: This contains all the information about leaves, such as Leaves Available, Leaves Used, and Total Leaves.

I want to use Power Automate to update the data on the second list [Employee Leave Balance Details] annually beginning on [January 1st], depending on the first list [Employee Leave Balance Management].

Let’s see how to achieve it step by step.

Update a SharePoint List Item from another SharePoint List Using Power Automate

Before creating the flow, you must have two SharePoint lists. For this example, I created two SharePoint lists with the following columns and data types:

Employee Leave Balance Management:

ColumnsData Types
Employee NamePerson or Group
Sick LeavesNumber
Annual LeavesNumber
Compassionate LeavesNumber
SharePoint List from another SharePoint list Using Power Automate

Employee Leave Balance Details:

ColumnsData Types
Employee NamePerson or Group
Sick Leaves AvailableNumber
Sick Leaves UsedNumber
Total Sick LeavesNumber
Annual Leaves AvailableNumber
Annual Leaves UsedNumber
Total Annual LeavesNumber
Compassionate Leaves AvailableNumber
Compassionate Leaves UsedNumber
Total Compassionate LeavesNumber
Total LeavesNumber
Total BalanceNumber
Total Leaves UsedNumber
Power Automate Update one Sharepoint list from another Sharepoint list

1. Sign in to Power Automate with valid credentials. Then click on + Create and Select Scheduled cloud flow. Enter the Flow name, and under Run this flow, provide the information below.

  • Starting: Select the date. From which date the flow will start?
  • at: Provide the time the flow will run.
  • Repeat every: Provide the interval. In my case, I want my flow to run every year, so I select 12 months.
How do I update one SharePoint list from another list using Power Automate

2. Then, add a Get items action and provide parameters such as Site Address and List Name. You can also change the action name to make it easier to identify. I named it Get items | Leave Balance Management.

Update item in a SharePoint list from another SharePoint list using Power Automate

3. Then add again the Get items action for Employee Leave Balance Details and provide parameters such as Site Address and List Name. You can also change the action name to Get items | Leave Balance Details.

Update Secondary SharePoint list using Power Automate

4. Now, I will add a Condition action that compares the two-person column emails in two different SharePoint lists. while adding, it will automatically take a For each loop. check the screenshot below.

How to update item in SharePoint using Power Automate from another SharePoint List

5. While I put the employee email in the equal to section, it will automatically take another for each loop. Check the screenshot below.

Power Automata update item in a SharePoint list from another SharePoint list

6. Then, inside the first for each loop, we need to store five things from Employee Leave Balance Management using the help of the compose action.

Name Inputs
IDitem?[‘ID’]
Employee Email IDitem?[‘EmployeeName’]?[‘Email’]
Sick Leavesitem?[‘SickLeaves’]
Annual Leavesitem?[‘AnnualLeaves’]
Compassionate Leavesitem?[‘CompassionateLeaves’]

For all the input values, I am taking from dynamic content.

How to update SharePoint list item with Power Automate

7. Now open the Condition action and add the output of the employee email id Compose action.

Power Automate Update record in List one from another List

8. Then, inside the true section, add an update item action to provide the Site Address, List name, and Id as output of the Compose | ID.

Update a SharePoint list from another SharePoint list using Power Automate

9. After that, in the Advanced parameters, select the column name you want to update in SharePoint. Here, I want to update the column with the expression Check the table below.

Column nameExpression
Sick Leaves Availableadd(item()?[‘SickLeavesAvailable’],outputs(‘Compose_|_Sick_Leaves’))
Sick Leaves Usedint(0)
Total Sick Leavesadd(item()?[‘SickLeavesAvailable’],outputs(‘Compose_|_Sick_Leaves’))
Annual Leaves Availableadd(item()?[‘AnnualLeavesAvailable’],outputs(‘Compose_|_Annual_Leave’))
Annual Leaves Usedint(0)
Total Annual Leavesadd(item()?[‘AnnualLeavesAvailable’],outputs(‘Compose_|_Annual_Leave’))
Compassionate Leaves Availableadd(item()?[‘CompassionateLeavesAvailable’],outputs(‘Compose_|_Compassionate_Leave’))
Compassionate Leaves Usedint(0)
Total Compassionate Leavesadd(item()?[‘CompassionateLeavesAvailable’],outputs(‘Compose_|_Compassionate_Leave’))
Total Leavesadd(add(add(item()?[‘SickLeavesAvailable’],outputs(‘Compose_|_Sick_Leaves’)),add(item()?[‘AnnualLeavesAvailable’],outputs(‘Compose_|_Annual_Leave’))),add(item()?[‘CompassionateLeavesAvailable’],outputs(‘Compose_|_Compassionate_Leave’)))
Total Balanceadd(add(add(item()?[‘SickLeavesAvailable’],outputs(‘Compose_|_Sick_Leaves’)),add(item()?[‘AnnualLeavesAvailable’],outputs(‘Compose_|_Annual_Leave’))),add(item()?[‘CompassionateLeavesAvailable’],outputs(‘Compose_|_Compassionate_Leave’)))
Total Leaves Usedint(0)
Power Automate update one SharePoint list column based on another lists data

Once the Flow is ready, we will move forward to run the Flow.

Run the flow to update the SharePoint list Item from another SharePoint list

Now click on ‘Save,’ then click ‘Test’ and select ‘Manually’ to run the test. You will see that the flow ran successfully.

Power Automate update SharePoint list item based on another list

After that, go to the Employee Leave Balance Details SharePoint list. You will see that the leave balance has been successfully updated.

How to update a SharePoint list from another SharePoint list using Power Automate

I hope you follow all the steps to update the SharePoint list item from another SharePoint list in Power Automate.

Also, you may like some more Power Automate articles:

>

Build a High-Performance Project Management Site in SharePoint Online

User registration Power Apps canvas app

DOWNLOAD USER REGISTRATION POWER APPS CANVAS APP

Download a fully functional Power Apps Canvas App (with Power Automate): User Registration App

Power Platform Tutorial FREE PDF Download

FREE Power Platform Tutorial PDF

Download 135 Pages FREE PDF on Microsoft Power Platform Tutorial. Learn Now…