I couldn't find a tool in ArcGIS Desktop (10.2.2) to convert a CSV into a shapefile, which was surprising to me, so I decided to script my own.
I found a helpful example script on ESRI's website (converting a dbf to layer) here: http://desktop.arcgis.com/en/arcmap/10.3/tools/data-management-toolbox/make-xy-event-layer.htm
I took the bulk of that script and added a CopyFeatures_management step to create the shapefile I wanted (relevant portions of my script below).
# Make the XY event layer arcpy.MakeXYEventLayer_management(Input_Table, x_coords, y_coords, XYevent_Layer, spRef) # Save to a layer file arcpy.SaveToLayerFile_management(XYevent_Layer, Saved_Layer_path) # Copy features to shapefile arcpy.CopyFeatures_management(Saved_Layer_path, Output_FC)
My script works fine.
But this seems like it should be a one-step task (CSV to shapefile).
Can anyone tell me what is going on "under the hood" that requires 3 separate steps, OR why ESRI doesn't have a CSV to shapefile tool? I don't see anything like that in the Conversion Tools folder.
I realize this question isn't focused on a problem per se, but I hope it is allowed because I think it would be valuable to those who want to better understand Arcpy scripting AND I've already tried searching the web to no avail.