Select to view content in your preferred language

merging two features from the same shapefile

4069
10
Jump to solution
11-22-2013 03:37 AM
BryceGardner1
Emerging Contributor
I have a shapefile with all the roads in my county. Unfortunately, they are in segments. I am trying to combine them all into the same shapefile where each road has one continuous segment instead of hundreds of little segments.

I thought about using a loop, SearchCursor, selectByAttribute, and unSplitLine, but that is going to put them all into separate shapefiles (or continuously overwrite them). I need them all in the same shapefile so I can run my analysis on them.

Any thoughts about how I can move forward are appreciated.

Thanks,

Bryce
Tags (2)
0 Kudos
10 Replies
XanderBakker
Esri Esteemed Contributor
I just tried using switching to MULTI-PART instead of SINGLE_PART. It worked! It doesn't matter if they are separated, the street names in our county aren't allowed to clash with one another. So, we only have one road name per road, instead of a weird situation where 11th St. is on two different sides of town. Thank you for all your help, Xander.


Hu Bryce,

Glad to hear that the multiparts work for you. In case you want to eventually correct the lines, there is a tool called "Flip Line (Editing)", which can flip the orientation of a polyline. (It is available for standard and advanced licenses.)


In ArcObjects the IPolyline interface has a ReverseOrientation method. I don't see this in arcpy, but it wouldn't be too difficult to write.

Kind regards,

Xander
0 Kudos