[postgis-users] pgAdminIII crashes when import SQL

Obe, Regina robe.dnd at cityofboston.gov
Tue Aug 19 07:08:37 PDT 2008


PgAdmin III is not designed for opening large sql files.  
 
You should be using  psql as you described - something like below
psql -h someserver -d gisdb -U someuser -f myshapefiles.sql
 
 
 If you are not local to the server, you need to specific the host name
too and run the above from a command line and preferably specify the
name of the user you are connecting as.  If you don't have trust between
the server and pc you are on - you will be prompted for password.
 
Its generally easier to just copy the sql file to the postgresql server
and use the psql command line locally.
 
Hope that helps,
Regina

________________________________

From: postgis-users-bounces at postgis.refractions.net
[mailto:postgis-users-bounces at postgis.refractions.net] On Behalf Of
Xiaoyu Guan
Sent: Tuesday, August 19, 2008 4:20 AM
To: postgis-users at postgis.refractions.net
Subject: [postgis-users] pgAdminIII crashes when import SQL


Dear all:
Here I have some problems with pgAdminIII. I am not a PostGIS
export,(neither SQL). but I still want to use PostGIS. I have two ESRI
shapefiles. each file have many attribute. here is some steps what I
did. 
Step 1. shp2pgsql. (win xp)
shp2pgsql -s 4326 -i -I myshapefile.shp myshapefile > myshapefile.sql

this step is work fine. I got two sql files, one is over 445MB, another
one is over 122MB. 

Step 2. using query tools in pgAdmin III . 
crashes happpens when I am opening the two sql file in query tools of my
database. my pc is Intel Core Dual, 2GB ram, then XP warning is that
some memory(0x00b45d2c) could not be writen. I attached screen shot.

some others. then I try to use psql command. 
psql -d mydatabase -f myshapefiles.sql

then I am not sure how psql works. I can use QGIS open the database, but
not my GeoServer or uDig. 

is there anyboday have similar situations before?

All the best 

Xiaoyu


-- 
Xiaoyu Guan (Sam)
Geo-information Science
Wageningen UR




-----------------------------------------
The substance of this message, including any attachments, may be
confidential, legally privileged and/or exempt from disclosure
pursuant to Massachusetts law. It is intended
solely for the addressee. If you received this in error, please
contact the sender and delete the material from any computer.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20080819/f3e84851/attachment.html>


More information about the postgis-users mailing list