Created
September 17, 2015 22:27
-
-
Save jczaplew/a04230573a09c7d68013 to your computer and use it in GitHub Desktop.
pg_dump raster error
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CREATE DATABASE test; | |
CREATE EXTENSION postgis; | |
CREATE SCHEMA rasters; | |
CREATE TABLE rasters.my_rasters ( | |
id serial NOT NULL, | |
rast raster, | |
CONSTRAINT enforce_pixel_types_rast CHECK ((public._raster_constraint_pixel_types(rast) = '{16BSI}'::text[])) | |
); | |
INSERT INTO rasters.my_rasters (rast) ( | |
SELECT ST_AsRaster( | |
ST_GeomFromText( | |
'LINESTRING(-108 30, -87 43)' | |
, 4326), | |
150, 150, '16BSI' | |
) | |
); | |
pg_dump -C test > ~/Downloads/test.sql && dropdb test && psql < ~/Downloads/test.sql |
Can be fixed by changing SET search_path = rasters, pg_catalog;
to SET search_path = public, rasters, pg_catalog;
in the dump file
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The following error will be thrown: