[postgis-users] Help: Ring not closed error when loading data via shp2pgsql

Wood Brent pcreso at pcreso.com
Mon Aug 23 22:30:39 PDT 2004



I have a shapefile to load into PostGIS.

When I run the SQL created with shp2pgsql, I get the following message,
psql:ross020107.sql:7: ERROR:  polygon has ring where first point != last point
followed by errors until the failed commit statement.

The polygons contain several rings & several thousand vertices, and I have
potentially a few hundred shapefiles to load.

Is there any way to give a more verbose error message to help identify the
erroneous Ring so I can edit in the closing coordinate pair. 

Could the "7" help find the polygon? What does it refer to?

Any suggestions as to how I can get closer to identifying the offending
polygon/ring appreciated.



Thanks,

   Brent Wood



More information about the postgis-users mailing list