Select to view content in your preferred language

Merging Coincident Events with Similar Attributes

906
4
03-03-2023 11:41 AM
AndrewLaux
Occasional Contributor

Is there a programmatic method within the LRS Server to "Merge Coincident Events with similar attributes"? I see this option available in the Event Editor application but was looking to see if there was a batch method to perform this.

This would be useful when the event layer has been unnecessarily split at a geographic location.

4 Replies
NathanEasley
Esri Regular Contributor

Hi Andrew,

Take a look at the allowmerge parameter within the lrsApplyEdits operation (https://developers.arcgis.com/rest/services-reference/enterprise/apply-edits.htm).  It should make the type of merge you're asking about.

Nathan
ArcGIS Pipeline Referencing team

0 Kudos
AyanPalit
Esri Regular Contributor

@AndrewLaux curious if the suggested lrsApplyEdits operation works for your use case? Please comment. There is a related enhancement idea for Event Dissolve geoprocessing tool that you can up-vote (kudo) as well. 

Ayan Palit | Principal Consultant Esri
0 Kudos
AndrewLaux
Occasional Contributor

Hi Ayan and Nathan,

Thank you for your input, that helps.  Although I am unsure as to whether this would apply to my case as the REST operation states that it only merges coincident events in the case of additions, not updates and deletions? In my case, the features  have already been loaded into the LRS database using the Append Events tool. In retrospect, could adding the Event Dissolve tool to a preprocessing workflow before performing Append Events be a solution to this issue?

0 Kudos
AyanPalit
Esri Regular Contributor

@AndrewLaux The "Dissolve Route Events" tool is in the Linear Referencing Tools. The tool allows you to specify dissolve field(s) as well as combine adjacent events. However, the output is created as a new table (not in-place). The tool will work great as part of initial/bulk load of events as a precursor to "Append Events". - as posted in the ArcGIS Ideas thread  Event Dissolve

As you rightly noted, lrsApplyEdits operation merges coincident events in the case of additions, not updates and deletions. I don't think merge applies to deletes - please elaborate if you have a specific example.

I can understand the update use case, but this could be error prone if done in bulk/programmatically. Consider alternate workflows to use:

  • Use Event Editor merge events tool
  • Use Event Editor replace events tool
  • Pre-process data using Dissolve Route Events followed by Append Events. If using this approach, explore the options in Append Events  to
    •  Retire overlaps
    • Retire by event ID
    • Replace by event ID

Hope this helps!

Ayan Palit | Principal Consultant Esri
0 Kudos