[postgis-users] Restore a raster dump from PostGIS 2.1.0 to PostGIS 2.3.0

Regina Obe lr at pcorp.us
Tue May 2 13:53:37 PDT 2017


Shane,

 

I've ticketed this issue here: https://trac.osgeo.org/postgis/ticket/3750

Most of these issues related to restore were fixed in PostGIS 2.3, but looks like you found a missed spot.

 

To fix, you should have a folder in your postgresql install share/extension with a file called postgis.sql

 

Search for $1 @ $2

 

Should be around line 4057

 

Change that to:

 

$1 OPERATOR(@extschema at .@) $2

 

 

And then try to reinstall your backup in a clean database.

 

Let me know if you still run into issues.

 

Thanks,

Regina

PostGIS PSC Member

http://www.postgis.us

http://postgis.net

 

 

 

 

 

From: postgis-users [mailto:postgis-users-bounces at lists.osgeo.org] On Behalf Of Shane StClair
Sent: Tuesday, May 02, 2017 3:55 PM
To: postgis-users at lists.osgeo.org
Subject: Re: [postgis-users] Restore a raster dump from PostGIS 2.1.0 to PostGIS 2.3.0

 

Was a solution to this problem ever discovered? I'm running into exactly the same problem (backup from PostGIS 2.1 with raster tables can't be restored to PostGIS 2.3).

 

HINT:  No operator matches the given name and argument type(s). You might need to add explicit type casts.

QUERY:  SELECT $1 @ $2 AND public._ST_CoveredBy($1,$2)

CONTEXT:  SQL function "st_coveredby" during inlining

COPY coei_166_3857, line 1: "1  010000010091C9D81F26AAE94091C9D81F26AAE9C082B6A532F81B73C103DAD0FE58846041000000000000000000000000..."

pg_restore: [archiver (db)] Error from TOC entry 187538; 0 223203 TABLE DATA coei_196_3857 asdf

pg_restore: [archiver (db)] COPY failed for table "coei_196_3857": ERROR:  operator does not exist: public.geometry @ public.geometry

LINE 1: SELECT $1 @ $2 AND public._ST_CoveredBy($1,$2)

 

 

On Fri, Nov 25, 2016 at 6:48 AM Cedric Duprez <Cedric.Duprez at ign.fr <mailto:Cedric.Duprez at ign.fr> > wrote:

Sorry, I thought I had installed PostGIS 2.1 on my backup server, but it is 2.3 that has been finally installed.

I don't understand how that could be.

The server is on Debian Jessie, and I did the following packages installation:

 apt-get update && apt-get install -y postgresql-9.3 postgresql-client-9.3 postgresql-contrib-9.3 postgresql-server-dev-9.3 && \
    apt-get install -y gdal-bin libgdal-dev && \
    apt-get install -y postgresql-9.3-postgis-2.1

Why do I get the 2.3 version of PostGIS installed? How can I downgrade to 2.1?

Thanks for you help.
Regards,

Cedric






Hi,

Still same issue with two servers having the same configuration.

Regards,

Cedric

 

 

 

_______________________________________________
postgis-users mailing list
postgis-users at lists.osgeo.org <mailto:postgis-users at lists.osgeo.org> 
http://lists.osgeo.org/mailman/listinfo/postgis-users

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20170502/d26d6ce0/attachment.html>


More information about the postgis-users mailing list