[postgis-users] Large WKT from file
yvecai
yvecai at gmail.com
Mon Feb 20 12:24:46 PST 2012
Hi all,
It's maybe more a bash question than a Postgis one, but ...
I'm extracting shapefiles from a SRTM contour lines postgis base, using
WKT multipolygons to cut extract by country.
This gives something like:
pgsql2shp -f shp/my_shapefile.shp -u mapnik contour \
"SELECT
ST_simplify(intersection(way,GeomFromText('$poly',-1)),0.00005),
height \
from contours where \
ST_Intersects(way, GeomFromText('$poly',-1));"
where $poly is a large WKT (like this one:
http://pistes-nordiques.org/download/france.wkt).
I have the following error: /usr/bin/pgsql2shp: Argument list too long
I played a little with xargs, but with no success. Is there a way to
load the wkt from a file with postgres, or something else?
yves
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20120220/55d5c814/attachment.html>
More information about the postgis-users
mailing list