Select to view content in your preferred language

Update shapefile's field using nearest shapelife

695
4
03-21-2019 07:57 AM
sotokan80_
Regular Contributor

I have a polyline shapefile (1.500.000 road segments) and  a point shapefile (the road segment's name). What is the most efficient way to update the polyline shapefile using info from the point shapefile.

Do i have to use a specific tool i.e SelectLayerByLocation_management and a cursor? Is there a more efficient way?

0 Kudos
4 Replies
by Anonymous User
Not applicable

Hi, 

You could look into doing a spatial join which will join the two attribute tables based on their spatial location. 

About joining the attributes of features by their location—Help | ArcGIS Desktop 

Hope this helps!

DanPatterson_Retired
MVP Emeritus

Near tool? Spatial Join? etc? depends on what you want the final results to look like

sotokan80_
Regular Contributor

The distance between point and polyline is calculated from polyline's middlepoint?

0 Kudos
DanPatterson_Retired
MVP Emeritus

not with Near Near—Help | ArcGIS Desktop or spatial join Spatial Join—Help | ArcGIS Desktop 

proximity is calculated for both of those using relationships described here

How proximity tools calculate distance—Help | ArcGIS Desktop