[postgis-users] shp2pgsql oddities

Steffen Macke sdteffen at web.de
Mon Dec 29 07:59:50 PST 2003


Hi Aaron,

> shp2pgsql -c northamerica.shp northamerica giswxtest
>
> Lots of stuff scrolls past the screen that look like Insert statements.

This is correct - shp2pgsql only creates the insert statements. You
have to execute them e.g. using psql. You can redirect the shp2pgsql output to
psql using | or you can redirect the output to a file and execute the 
statements from that file.

The following is an example - you may have to add additional parameters
for host/username to psql as required:

shp2pgsql -c northamerica.shp northamerica giswxtest | psql -d giswxtest

Steffen




More information about the postgis-users mailing list