[postgis-users] shp2pgsql segmentation fault using -a option
rkgeorge at cadmaps.com
Mon Dec 29 15:47:37 PST 2003
Here is another novice question about the shp2pgsql translator.
I am running the translator in a SUSE 9.0 Linux with PostgreSQl and PostGIS
installed on a USA state bdry states.shp file which was taken from an
ArcView sample data directory.
When I run the translator as follows there is no problem:
1. shp2pgsql -D states.shp test GISTest > test.sql
2. shp2pgsql -d -D states.shp test GISTest > test.sql
3. shp2pgsql -s 4269 -d -D states.shp test GISTest > test.sql
any of the above allow me to use:
psql -f test.sql -d GIStest
The only problem appears to be in the attempt to "drop sequence
GISTest_test_seq" even after the SELECT pg_catalog.setval('test_gid_seq',
50, true); statement is completed (running the psql command a second time).
It looks like the drop table test; also drops the sequence test_gid_seq so
that even if the drop sequence is changed to match test_gis_seq there will
be an ERROR indicating the sequence does not exist.
Note: This doesn't affect the import of the data.
**** However when I run shp2pgsql as follows I get a segmentation error:
4. shp2pgsql -a -D states.shp test GISTest > test.sql
Is the -a append option intended to update the sequence value? Does the
sequence value need to be tracked by the translation software or is it
Thanks for any help.
More information about the postgis-users