AnsweredAssumed Answered

Compare spatial and attribute changes between two feature classes and use changes to update other feature classes

Question asked by prymtym on Oct 7, 2020
Latest reply on Oct 7, 2020 by bharold-esristaff

I have two line feature classes, I need to compare the two(One being constantly edited) to see changes done on the spatial and attribute information, and also be able use these changes to update a master feature class. I need to develop python script or an Arcpy tool to that.

I started with detecting feature changes too in ArcMap and this is what I have so far, Any help would be greatly appreciated. I used shapefiles in the sample code

import arcpy
from arcpy import env

# Set environment settings
env.overwriteOutput = True
env.workspace = r""

# Set local variables
updateFeatures = "O:\All_In\GIS Projects\blocks\blocks\Streetlines_Updated.shp"
baseFeatures = r"O:\All_In\GIS Projects\blocks\blocks\Streetlines_Updated 2020.shp"
dfcOutput = r"O:\All_In\GIS Projects\blocks\blocks\latestUpdates.shp"

search_distance = "300 Feet"
match_fields = "name, class"

statsTable = "new_roads_stats"

# Perform spatial change detection
arcpy.DetectFeatureChanges_management(updateFeatures, baseFeatures, dfcOutput, search_distance, match_fields)

Outcomes