With this formula you will save a lot of time and nerves. Because you can easily add the current row numbers to any collection (or via patch also data table). Watch this video.
DropColumns ( XY, row ),
“row” , CountRows (tempCollection)+1),
You can see this video here on my blog because I have rated this video with 5 stars in my Youtube video library. This video was automatically posted using PowerAutomate.