QGIS – How to Clip Very Large Shapefile Using ogr2ogr

clipogr2ogrqgisshapefile

I need to clip a large shapefile (600,000 KB) to another smaller shapefile (10 KB). The vector -> geoprocessing -> clip command is taking very long. Answers to similar questions say to use "ogr2ogr" but I am not sure where to start in installing ogr2ogr. I have no Python experience either, not sure if that makes a difference.

Best Answer

On windows environnement, if you installed Qgis with OSGeoW setup you have access to a shell which can run directly gdal/ogr. to run a clic processing use this command
ogr2ogr -clipsrc clip_polygon.shp output.shp input.shp
replace output and input with your files name and their path.
If you need more details about OSGEOW have a look to this page