<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
I suspect your merge process worked because you added an attribute
column (gid) to the exported geometries. <br>
<br>
Try adding some attribute on the fly ... something like this:<br>
<br>
pgsql2shp -f polys.shp postgis "SELECT null::char AS blank_attr,
the_geom FROM my_poly_table"<br>
<br>
-- Kevin<br>
<br>
<br>
On 11/17/2010 5:32 AM, Thomas Kouk wrote:
<blockquote cite="mid:856960.12968.qm@web27805.mail.ukl.yahoo.com"
type="cite">
<style type="text/css"><!-- DIV {margin:0px;} --></style>
<div style="font-family: arial,helvetica,sans-serif; font-size:
12pt;">
<div>I left the -a_srs out and I no longer have the usage
information, but instead I have an error message: </div>
<div>ESRI Shapefile driver failed to create file.shp. </div>
<div>The same happens for other spatial tables as well (not
necessarily polygons).</div>
<div> </div>
<div>The table contains only a geometry column. The funny thing
is that if I use a script to merge a lot of such tables into
one, adding a gid column so that I can distinguish them, using
the command I tried in the beginning:</div>
<div> </div>
<div> pgsql2shp -P [password] -f [shapefile path & name]
postgis [tablename]</div>
<div> </div>
<div>works fine! However it would be stupid to create another
script to split the data and deal with this in this way.<br>
</div>
</div>
<br>
</blockquote>
</body>
</html>