[Qgis-user] Clipping 60 shape layers

Koos Hagg hagg.koos at gmail.com
Mon May 7 05:56:41 PDT 2012


Hi All,
have been searching around for the answer to this question, and found an
old thread on this list.

I have a folder which contains about 30 shapefiles, old (but still useful)
vmap0 data, but it is 500mb in size. I'd like to clip each shapefile to
just the region I need.
I understand about ogr2ogr, and I could do it one by one,

but I would like to figure out how to write a batch file to do it all at
once. However- I have been trying this and that for a while, not making any
progress.

any help is appreciated!


Koos



Date: Thu, 15 Mar 2012 19:59:44 +0200
From: Zirneklitis <eko at lanet.lv>
Subject: Re: [Qgis-user] Clipping 60 shape layers
To: qgis-user at lists.osgeo.org

Use ogr2ogr:

ogr2ogr -f "ESRI Shapefile" -clipsrc mask.shp output.shp input.shp

Karlis

Bis Nulama wrote:
> ..
> I have 60 shape layers and I would like to cut them on a poligon shape
> (region boundary).
> Is there a way to do this selecting all the 60 layers at once (and not
> repeating the clip command 60 times)?
> ..
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-user/attachments/20120507/ce001f6e/attachment.html>


More information about the Qgis-user mailing list