[postgis-devel] raster2pgsql error?

Pierre Racine Pierre.Racine at sbf.ulaval.ca
Wed Mar 7 10:41:24 PST 2012


What do you mean by empty? Does QGIS show an empty square or just nothing?

> -----Original Message-----
> From: postgis-devel-bounces at postgis.refractions.net [mailto:postgis-devel-
> bounces at postgis.refractions.net] On Behalf Of dustymugs
> Sent: Wednesday, March 07, 2012 1:20 PM
> To: postgis-devel at postgis.refractions.net
> Subject: Re: [postgis-devel] raster2pgsql error?
> 
> On 03/07/2012 10:12 AM, Salvatore Larosa-1 wrote:
> > Hi,
> > I'm trying to import a tif raster [1] into PostGIS but I have a problem!
> >
> > raster2pgsql command seems to run correctly, but when I try to display
> > the raster in qgis my map is empty!
> >
> > below what i do:
> >
> > 1] postgres at debian:~$ raster2pgsql -s 4236 -I -C -M
> > /home/sam/pgraster_test/katrina.tif -F -t 64x64 public.katrina>
> > /home/sam/pgraster_test/katrina.sql
> >
> > 2] postgres at debian:~$ psql -f /home/sam/pgraster_test/katrina.sql -d
> > workshop
> >
> > in QGIS:
> >
> >>>> from qgis.utils import iface
> >>>> connection = "PG:host='localhost' port='5432' dbname='workshop'
> >>>> user='postgres' password='*******' schema='public' table='katrina'
> >>>> mode='2'"
> >>>> iface.addRasterLayer(connection, "katrina")
> >
> > Any hint?
> >
> >
> 
> First, check to see if there is data in any of the three bands of that raster.
> Something like
> 
> SELECT ST_SummaryStats(rast) FROM public.katrina
> 
> If there are counts, there is data.
> 
> My guess is that QGIS isn't rendering correctly.  I can't say much about the
> PostGIS Raster plugin as it has been a while since I tried using it and at last
> check, it was out-of-date with regards to PostGIS trunk (to become 2.0).
> 
> -bborie
> _______________________________________________
> postgis-devel mailing list
> postgis-devel at postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-devel



More information about the postgis-devel mailing list