[postgis-users] pgsql2shp - problems

strk strk at keybit.net
Fri Feb 6 00:33:42 PST 2004


havard.tveite wrote:
> pgsql2shp fails on my Solaris 2.6 (gcc 2.95.3). PostGIS CVS from
> 4. february, pgsql 7.4.1, geos CVS from 4. february.
> When setting DEBUG and VERBOSE, the following output is produced:
> 
> pgsql2shp ....
> Initializing... Done.
> Dumping: Xiii
> -----
> ByteOrder: NDR
> Type: 1060000
> -----
> gBus Error(coredump)
> 
> When commenting out #define USE_WKB, things work better:
> 
> pgsql2shp ....
> Initializing... Done.
> Dumping: XiiigFinished adding record 0
> iiigFinished adding record 1
> iiigFinished adding record 2
> ....
> iiigFinished adding record 98
> iiigFinished adding record 99
> End of result, clearing...Done.
> X [100 rows].
> 
> The geometries are MULTIPOLYGON, SRID=326233, coordinate
> dimension is 2. It is the geometry that seems to be causing
> the problems.
> 
> "shape_creator(val, row)" is the line (1975 in pgsql2shp.c)
> that fails. "shape_creator" should in this case be
> "create_multipolygon2D_WKB(val, row)" ?

Yes, it *should*. You can make that func print a message to make sure. 
Is NDR (LittleEndian) the correct WKB format for Solaris ?
Have you tried the -b option ?

--strk;



More information about the postgis-users mailing list