I have been working on a Tool for a couple of years now and have been slowly updating it based on user feedback and needs. This Tool uses Microsoft Power Automate to copy a lot of data to different layers so users aren't having to do it manually. The last part of the workflow takes a polygon and some associated attributes from an ArcOnline hosted feature layer and pastes it into a feature layer on our Enterprise system. I had assistance from Esri to get this running (we had hours through our organization's agreement for technical help). I have attached a screenshot of the Flow (Copy_to_Portal_PA.png).
I am now testing a process to see if it's feasible as a solution to a problem, and it seems like it will work, but I don't have the specific Flow steps correct. I again want to copy a polygon record from a hosted feature layer to the layer on our Enterprise system, but the hosted feature layer now has a related table. The trigger to copy the record is updating an attribute in the related table, copying the parent polygon, some of the parent's attributes, and some of the child's attributes to the Enterprise layer. I used this great post to be able to "see" the related table in Power Automate, but my Flow isn't being triggered. Based on the previous assistance I received from Esri, there is an extra step/missing step/wrongly nested step that's causing this, but I can't find it. Can anyone help? I've attached two additional screenshots of my new Flow (PA_1.png and PA_2.png) to show what I created. Please let me know if you need more information.
@AnninaRupe1 Thanks for your question, I or someone else will look into this. Is the flow working and not doing what it supposed to? or Do you see an error somewhere
@AkshayHarshe: I'm actually talking with a couple of solution engineers who will be reaching out to you more about my workflow! But for now, I don't have any errors to pass on because the Flow isn't being triggered, even though I updated the attribute that's supposed to trigger it. I basically copied the original Flow that runs fine and added the related table aspect, and now it doesn't trigger at all.
Hi, in addition to other comments, please confirm if the record that is supposed to trigger the webhook has been edited or deleted by another system?
I have created a brand-new hosted feature layer to test out my workflow; the record that's supposed to trigger the webhook is only being used for this new Flow and isn't being edited/deleted by anything else.
Hi, from the image, I do not see any issues with the flow, but I have some questions: 1- Why are you using 'terminate' at the end?
2- What are the response and initialization actions (actions 2 and 3)?
Just to confirm that your issue #1 is that the flow is not being triggered.
To assist here, please check if the flow was saved successfully.
Please check this screen to ensure no alerts are shown:
Check that the target layer is the layer you are editing. Not a view or vice versa.
I actually don't know the exact reason why the terminate, response, and initialization actions were needed. I have a Flow that's currently being used to copy from a hosted feature layer to an Enterprise layer (same workflow except without the related tables). I was having trouble with this last year and was able to use some technical assistance hours to get Esri help in creating the Flow. The analyst added these actions.
I opened the Flow and made sure the connections were good and saved it. At the top of the Flow, it stated that it was ready to go (see the attachment called Save_Successful.png). Then, when I returned to the Flow's management page, it gave me an error (see the Flow_Checker_Error.png attachment). I then clicked on the "Go to the trigger" link and the Run Details stated that there was an "Error creating webhook" (see attachment called "Error_Creating_Webhook.png). I did a bit of research and found that I didn't have the "Keep track of changes to the data" setting turned on. After I updated this setting in ArcOnline, the Flow triggered. However, the conditions were set incorrectly so the Flow didn't complete. I updated the conditions and the next time I updated the attribute to trigger the Flow, it failed (see the Flow_Fail.png screenshot). The "For Each" actions wouldn't stop spinning so I can't see what the error is there. I also don't know why there are so many "For Each" actions; they just keep getting added when I added other actions to my Flow.
The target layer is a hosted feature layer; not a view.
I did some more testing:
I modified the Flow down to the bare minimum so I could first test the Trigger:
The Trigger works: I updated an attribute in the related table and it sent an email.
However, the data in the email aren't correct. In my hosted feature layer, I have two polygons. One has one related record and the other has two related records. I only updated one attribute in one related record of the related table of the polygon that has two related records. I received two emails, both with the same data from the updated related table record but the parent polygon data were for different polygons. So it sent an email for both polygons but assigned the same related record to both.
To me, this means that the related table isn't connected to the parent layer somewhere. I tried to put a condition in (ParentRecord (attribute from related table) is equal to GlobalID (attribute from parent layer)), but when the Flow is triggered, it follows the "False" part of the flow.
Been working with a great team of Esri analysts! Here's an update:
Whittled the flow down to this:
If I remove the date attribute to write the Flow works. Looks like the big issue was flipping when to fetch related table updates and getting parent data. Will update more when I can!