Wednesday, 3 February 2016

convert - Converting between KML and shapefile (SHP) format?



My users are sending me point data that were digitized using Google Earth.


How can I convert their KML to a shapefile?



Answer



Using the open source ogr2ogr from GDAL/OGR:


ogr2ogr -f 'ESRI Shapefile' output.shp input.kml

As noted in grego's comment below, you may need to use double quotes instead of single quotes for the output format option (e.g. "ESRI Shapefile" for the Windows command line). See also the gdal wiki.


No comments:

Post a Comment

arcpy - Changing output name when exporting data driven pages to JPG?

Is there a way to save the output JPG, changing the output file name to the page name, instead of page number? I mean changing the script fo...