Hi
So I have a list of premises in a spreadsheet (Premise_Targetting.xls) which staff need to visit over the next few years. Staff are required to input the time and date they attended, the outcome of the visit and the staff members name. I have set this up using data validation to ensure data quality.
I have created a flow which works on a schedule (overnight) once a day. It basically takes rows from Table 1 that have been completed, and copys them to table 2. BUT it's then supposed to delete the record from Table 1.
See attached
So the flow works perfectly until it needs to delete all those that have 'Yes' in the QA column (these have been flagged as having passed the QA process). Have i used the Delete a Row correctly? Why is it failing on the delete a row?
Has anyone else done this successfully?
Any help would be greatly appreciated.
Hi @KelLew88 ,
May I know is there any progress or do you need any further help?
Community Support Team _ Wenjuan Zou
If this post helps, then please consider Accept it as the solution to help the other members find it.
Hi @KelLew88 ,
Sorry but I'm not expert on Excel...I do a research online and find something may help under your scenario.
Solved: unlock excel file with Flow - Power Platform Community (microsoft.com)
How to clear annoying Excel file locks in Power Automate – CleverWorkarounds
For "data validation rule" part, still I'm not expert on Excel. To narrow down the issue, you may check flow run's "Add a new row into a table" outputs to see whether flow pass those data to table 2. If yes, that's mean flow has sent out the request but somehow the Excel refuse the data maybe for the mentioned "data validation rule"... If so, you may need to cancel the rule once you want the flow running well...
Community Support Team _ Wenjuan Zou
If this post helps, then please consider Accept it as the solution to help the other members find it.
I have also just noticed that my date and time fields are not being moved across to the new table in the flow, even though they were complete. E.g. we have 3 visit dates/times fields. These do not all have to be completed if the job was done at the first or second visit, so there are blanks sometimes. I have checked my flow and all fields are mapped to the right columns in the second table. so can't work out why they are not being added at the Add Row into table step. Could it be because there is a data validation rule on these date/time fields in table 1?
Any ideas would be welcome 🙂
Thanks
Thank you! I have a slight issue i've discovered though. Flow now works thanks for your suggestion but my issue is that the spreadsheet is protected with a password.
Is it possible to "Run a Script" which unlocks the spreadsheet within the flow. I've noticed that if the sheet is protected the flow fails at the "delete a row". But when it's not protected it runs successfully. Logically i understand that this is probably not possible but I'm hoping there might be a work around?
Thanks
Hi @KelLew88 ,
You need to insert in "Key column" with a column filling with unique value. Otherwise, the "Delete a row" will retrieve several rows and cause the issue.
To fix it, you can add an "ID" column in your first list filling with unique number for each row.
Delete your "Apply to each 2" and add "Delete a row" right after "add a row into a table". Choose "ID" column as key column and insert dynamic content of "ID" column into "Key value".
Community Support Team _ Wenjuan Zou
If this post helps, then please consider Accept it as the solution to help the other members find it.
Michael E. Gernaey
179
Super User 2025 Season 1
David_MA
161
Super User 2025 Season 1
stampcoin
143