[postgis-users] postgis_restore.pl loads no data (pg-8.1, postgis-1.1)

Benjamin Thelen bt at ccgis.de
Mon Jan 16 04:29:56 PST 2006


Another attempt:

My FreeBSD 6 box at home, installed a postgres-8.1.2, postgis-1.1.0, 
converted some shape data with shp2pgsql and made a backup with pg_dump 
-FC. I again could not successfully upload the backup with 
postigs_restore.pl.


Again, using postgis_restore.pl from postgis 1.0.6 or downgrading, leads 
to a successful upload.

No more ideas.

Best,
Ben






strk at refractions.net schrieb:
> Please give postgis_restore.pl a try and let use know.
> 
> --strk;
> 
> On Thu, Jan 12, 2006 at 07:50:19PM +0100, Benjamin Thelen wrote:
>> Hi list,
>>
>> I backed up a postgresql/postgis DB from a 
>> postgresql-8.0.4/postgis-1.0.4 combination and tried to restore the dump 
>> into a 8.1.2/1.1.0 combination and failed. It seems that all 
>> (functions,..) but the data itself is uploaded. The procedure just stops 
>> as it seems without any error message. Please have a look at the end of 
>> the output below.
>>
>> The most interesting part is that I also tried to upload the same dump 
>> into the same DB but using an old postgis_restore.pl from postgis-1.0.4 
>> and succeeded! At least it seems at first glance. In this case the 
>> output doesn't stop as you see below, but continues to load the data 
>> itself into the database.
>>
>>
>> I couldn't find anything on the internet, just the information, that 
>> postgis itself is pg-8.1 compatible and postgis_restore.pl hasn't 
>> officially been testet with this pg version.
>>
>>
>> I'm a bit at a loss. Do I have to go back to 8.0? Is there something 
>> I've overlooked, I can do?
>>
>> Thanks,
>> Ben
>>
>>
>> .
>> .
>> .
>> LANGUAGE 'plpgsql' IMMUTABLE STRICT;
>> CREATE FUNCTION
>> --
>> -- SFSQL 1.1
>> --
>> -- BdMPolyFromText(multiLineStringTaggedText String, SRID Integer):
>> MultiPolygon
>> --
>> --  Construct a MultiPolygon given an arbitrary
>> --  collection of closed linestrings as a
>> --  MultiLineString text representation.
>> --
>> -- This is a PLPGSQL function rather then an SQL function
>> -- To raise an exception in case of invalid input.
>> --
>> CREATE OR REPLACE FUNCTION BdMPolyFromText(text, integer)
>> RETURNS geometry
>> AS '
>> DECLARE
>> 	geomtext alias for $1;
>> 	srid alias for $2;
>> 	mline geometry;
>> 	geom geometry;
>> BEGIN
>> 	mline := MultiLineStringFromText(geomtext, srid);
>>
>> 	IF mline IS NULL
>> 	THEN
>> 		RAISE EXCEPTION ''Input is not a MultiLinestring'';
>> 	END IF;
>>
>> 	geom := multi(BuildArea(mline));
>>
>> 	RETURN geom;
>> END;
>> '
>> LANGUAGE 'plpgsql' IMMUTABLE STRICT;
>> CREATE FUNCTION
>> ---------------------------------------------------------------
>> -- END
>> ---------------------------------------------------------------
>> COMMIT;
>> COMMIT
>> DROP TABLE geometry_columns;DROP TABLE spatial_ref_sys;
>> DROP TABLE
>> DROP TABLE
>>
>>
>> _______________________________________________
>> 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