[Qgis-user] QGIS and PostGIS raster (out-db)

Jorge Gustavo Rocha jgr at geomaster.pt
Mon Oct 18 07:42:52 PDT 2021


Hi Tim,

No problem here with rasters out of db.

Postgresql needs to know where the raster is and must have access to it 
later, when you open it on QGIS.

Try moving the raster to Postgresql data folder. Run 'SHOW 
data_directory;' to know where Postgresql stores the data. Copy the 
raster to that folder and try again with the full absolute path.

Regards,

Jorge Gustavo

On 18/10/21 04:04, tim dunlevie wrote:
> Hi all,
>
> Was wondering if someone has a similar experience.
> I'm testing storing raster data in my PostGIS db as an 'out-db' option.
> It seems to work via the raster2pgsql command line.
> The table is generated and I can see the table thru the QGIS 
> browser/DB Manager.
> However, if I drag/drop onto the map I get nothing.
> I can, however, zoom to the extents of the image....but I get no image 
> appearing.
> The image is a geotiff.
> In-database option works fine.
> I'm using QGIS v3.20.3-Odense with Postgresql 13.4 windows.
> Has anyone had success managing their raster data like this and 
> viewing in QGIS ?
>
> My command to store out-db image is below:
> |raster2pgsql -s 28350 -C -I -F “path\[image_name].tif" 
> [schema1].[tablename] -R | psql -h localhost -d spatialDB -U postgres 
> -p 5432|
>
> thanks
>
> _______________________________________________
> Qgis-user mailing list
> Qgis-user at lists.osgeo.org
> List info:https://lists.osgeo.org/mailman/listinfo/qgis-user
> Unsubscribe:https://lists.osgeo.org/mailman/listinfo/qgis-user
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-user/attachments/20211018/41ebabec/attachment.html>


More information about the Qgis-user mailing list