[postgis-users] (no subject)

Chrystel Losier chrystel.losier at reseauzec.com
Wed Oct 29 12:41:42 PDT 2014


I am fairly new to PostGIS and need to append data from a shp to an already
existing table in PostGIS. All the columns from the shp and the table are
the same, except that the shp does not already contain the geometry column
and the primary key column. I am using the following command line to append
the data :



"C:\Program Files\PostgreSQL\9.3\bin\shp2pgsql.exe"  -g the_geom -W latin1
-s 900913 -a peche_gue_final_projeter.shp corpo.peche_gue  | "C:\Program
Files\PostgreSQL\9.3\bin\psql.exe" -h demo.spatialytics.com -d zec_quebec
-U jlabelle –q



I get the following error message :



Error : duplicate key value violates unique constraint « peche_gue_pkey »

Details : Key « id_p_gue » = « 1 » already exists.



The table in PostGIS to which I want to append data already has a primary
key column : . « id_p_gue » which is in serial.



Any ideas how to deal with this problem?



Thanks!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20141029/d2d9b2fc/attachment.html>


More information about the postgis-users mailing list