<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=ISO-8859-1">
</head>
<body bgcolor="#ffffff" text="#000000">
Hi all,<br>
It's maybe more a bash question than a Postgis one, but ...<br>
<br>
I'm extracting shapefiles from a SRTM contour lines postgis base,
using WKT multipolygons to cut extract by country.<br>
This gives something like:<br>
<blockquote>pgsql2shp -f shp/my_shapefile.shp -u mapnik contour \<br>
"SELECT
ST_simplify(intersection(way,GeomFromText('$poly',-1)),0.00005),
height \<br>
from contours where \<br>
ST_Intersects(way, GeomFromText('$poly',-1));"<br>
</blockquote>
where $poly is a large WKT (like this one:
<a class="moz-txt-link-freetext" href="http://pistes-nordiques.org/download/france.wkt">http://pistes-nordiques.org/download/france.wkt</a>).<br>
<br>
I have the following error: /usr/bin/pgsql2shp: Argument list too
long<br>
<br>
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?<br>
<br>
yves<br>
<br>
<br>
</body>
</html>