Hello I have a flow that copies information from an excel sheet on my onedrive that's constantly updated and I have a issue that When it writes to the sharepoint list, it will only copy the first entry in the excel sheet then repeat the same entry over and over again. I have over 900 different entries. Any idea where would the mistake be? If I do this manually (create items, it works, but takes over 15 minutes)
Please see picture of flow below:
Solved! Go to Solution.
Hi @Sahara22
Remove the above steps, the inner loop and move the settings and Generate SP data under the first loop.
Select only expects the array of the values. Here you have mapped the emp name under the loop hence you got another loop. Also I can't see your first very first apply each 2? Is that reading from another Excel sheet? If its the same excel sheet then all you need is Get List rows and your select actions steps. Without seeing the full flow its difficult to give an exact answer.
If you liked my response, please consider giving it a thumbs up
Proud to be a Flownaut!
Learn more from my blogIt's like a constant loop, it wont stop until i cancel the flow ... Im not sure what I did, but like i said, if I use the "create items" and not use the script it works.
Hi @Sahara22
Remove the above steps, the inner loop and move the settings and Generate SP data under the first loop.
Select only expects the array of the values. Here you have mapped the emp name under the loop hence you got another loop. Also I can't see your first very first apply each 2? Is that reading from another Excel sheet? If its the same excel sheet then all you need is Get List rows and your select actions steps. Without seeing the full flow its difficult to give an exact answer.
If you liked my response, please consider giving it a thumbs up
Proud to be a Flownaut!
Learn more from my blogThank you fr replying back @abm ,
Here is the pic for the flow from the beginning, so the reason why I have this set up, because the table ID of the excel sheet constantly changes. So are you saying that I don't need "list rows"? Hope this picture helps you better to understand. Thank you again so much!!
I removed those to actions and now i get an Error saying:
"The execution of template action 'For_Each_row_in_the_Excel' failed: the result of the evaluation of 'foreach' expression '@body('List_rows_present_in_a_table')' is of type 'Object'. The result must be a valid array."
The expression I used for EMP_ID is
items('For_Each_row_in_the_Excel')?['EMP_ID']
Do I need to write this differently then because I removed it?
What the flow looks like now :
Any idea's?
Hi @Sahara22
What's the first step for? Do you have more than one tables in your Excel sheet?
If you liked my response, please consider giving it a thumbs up
Proud to be a Flownaut!
Learn more from my blogNo only one table. but it changes because the excel file is updated constantly so the table would get an error saying" could not find table" that's why I have to do "get tables".
Hi @Sahara22
What is that action step settings2?
Thanks
If you liked my response, please consider giving it a thumbs up
Proud to be a Flownaut!
Learn more from my blogthis one?
This is the top of the flow, hope this makes it easier for you. I have a flow that deletes then replaces info.
@abm Thank you for you help. It was because I had the second loop, thats why it was repeating the same entry. Removed looped and it works now. Thank you.
User | Count |
---|---|
94 | |
39 | |
24 | |
21 | |
16 |
User | Count |
---|---|
128 | |
49 | |
48 | |
32 | |
24 |