Move items from MS-Excel to SharePoint using Power Automate

Loading

Requirement : How to share/save data from MS-Excel to SharePoint list using Power Automate, OneDrive
when enter the data in the excel which saved in OneDrive

Initially we create a Excel in the desktop or can directly create in OneDrive in the same Microsoft account which you’re going to use to create the Power Automate

Create a table template using table design in MS-Excel, provide the require data & name the Table as required, save the MS Excel with a required name too.

As creating a table with student details.

  • Save this MS-Excel to OneDrive
  • Saved the Excel as Studenttab book.xlsx

Now upload the excel template in SharePoint site as a list to get the headers

Go to Home page of SharePoint site
–> Click on +New
–> List
–> click on From Excel
–> Upload Excel file from desktop

SharePoint list been created using Excel named as student-tab book all the column headers been retrieved from excel [except the first column will be Title because the SharePoint list contains the default column, can change the name of the title but in the backend it will be as ‘Title’]

Now creating the Power Automate flow to get the items from OneDrive and to save in SharePoint list

Create a flow trigger ‘when an item is created’ or as per your require

As the trigger used is ‘manually trigger a flow’

The Second action we use is ‘List rows present in a table’ and provide the require data into the fields

The next action would be ‘Apply to each’ and get the values Outputs from List_rows_present_in_a_table Apply to each.

Inside the ‘Apply to each’ insert Get items action and provide the required fields

site address : link from SharePoint site

list name : list from the SharePoint site

Filter Query : Title eq ‘Student Id'(Title from SP list & Student ID from list rows present in a table)

Take a control condition and provide the expression ‘length’ with the outputs of value from Get items

the condition should be as ‘length is equal to 0’ or ‘length is not equal to 0’ depends on the filter criteria

length(outputs('Get_items')?['body/value'])

Now in the Yes statement, use action apply to each,
Inside the ‘Apply to each’ insert Update items action and provide the required fields

In the No statement, use action ‘Create item’ and provide the required fields

Now test the manually and check for the records in the SharePoint list student-tab book

Final outputs, when we test the flow manually the flow would get the table data from the excel (OneDrive) and will save the data into the SharePoint list.

Leave a Reply

Your email address will not be published. Required fields are marked *