[postgis-users] Error while importing data

strk at refractions.net strk at refractions.net
Fri Jun 3 17:05:25 PDT 2005


On Sat, Jun 04, 2005 at 12:01:02AM +0000, Aditya wrote:
> On Sat, Jun 04, 2005 at 01:21:01AM +0200, strk at refractions.net wrote:
> > It sounds as you upgraded postgis in a wrong manner,
> > can you show the output of SELECT postgis_full_version() ?
> 
> Hm, that's odd, I didn't upgrade postgis, I did a fresh install...but in any

Mmm.. are you sure the shp2pgsql application is the one coming with
postgis 1.0.1 ? Calling it w/out args should tell you the RCSID.
--strk;

> case:
> 
> grot=> SELECT postgis_full_version();
>                    postgis_full_version
> ----------------------------------------------------------
>  POSTGIS="1.0.1" USE_STATS DBPROC="0.3.0" RELPROC="0.3.0"
> (1 row)
> 
> grot=> select version();
>                                               version
> ----------------------------------------------------------------------------------------------------
>  PostgreSQL 8.0.3 on sparc64-unknown-freebsd6.0, compiled by GCC gcc (GCC)
> 3.4.2 [FreeBSD] 20040728
> (1 row)
> 
> Thanks,
> Adi
> 
> > On Thu, Jun 02, 2005 at 09:03:20PM +0000, Aditya wrote:
> > > I'm getting an error similar to what was described in this thread from March
> > > 2005. I searched for 
> > > 
> > >  postgis "ERROR:  Invalid type in wbk"
> > > 
> > > and found this thread, but with a fix that seems not to apply to the
> > > shapefiles I'm trying to import. I would appreciate it greatly if someone else
> > > could try and reproduce this error (and thereby implicate the shapefile :-)
> > > 
> > > The shapefile was produced from:
> > > 
> > >   http://www.esri.com/data/download/basemap/index.html
> > > 
> > > and trying to import it using shp2pgsql on fresh installs of:
> > > 
> > >   postgis 1.0.1
> > >   postgresql 8.0.3
> > > 
> > > shapefile and resulting .sql file appended. The transcript of my sessions are
> > > below.
> > > 
> > > Thanks,
> > > Adi
> > > 
> > > some[ttyp0]:aditya/usr/local/src/gis/sa> /usr/local/pgsql/bin/shp2pgsql -d -D
> > > Country\ Boundaries\ 2.shp geoserver.country > country.sql
> > > Shapefile type: Polygon
> > > Postgis type: MULTIPOLYGON[2]
> > > some[ttyp0]:aditya/usr/local/src/gis/sa> psql -d grot -U geoserver -f country.sql 
> > > psql:country.sql:1: ERROR:  column not found in geometry_columns
> > > table
> > > CONTEXT:  SQL statement "SELECT  DropGeometryColumn('', $1 , $2 , $3 )"
> > > PL/pgSQL function "dropgeometrycolumn" line 4 at select into variables
> > > psql:country.sql:2: ERROR:  table "country" does not exist
> > > BEGIN
> > > psql:country.sql:4: NOTICE:  CREATE TABLE will create implicit sequence
> > > "country_gid_seq" for serial column "country.gid"
> > > psql:country.sql:4: NOTICE:  CREATE TABLE / PRIMARY KEY will create implicit
> > > index "country_pkey" for table "country"
> > > CREATE TABLE
> > >                                   addgeometrycolumn
> > > --------------------------------------------------------------------------------------
> > >  geoserver.country.the_geom SRID:-1 TYPE:MULTIPOLYGON DIMS:2
> > >  geometry_column fixed:0
> > > (1 row)
> > > 
> > > psql:country.sql:6: ERROR:  Invalid type in wbk
> > > CONTEXT:  COPY country, line 1, column the_geom:
> > > "00000000060000000100000000030000000100000070404E25B23571D1D4404259FF2E48E8A84050296B3354C122404259FF..."
> > > ROLLBACK
> _______________________________________________
> postgis-users mailing list
> postgis-users at postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-users



More information about the postgis-users mailing list