Question

Google Cloud SQL supports the PostGIS extension, but I haven't seen any documentation regarding how to work with raster data on it. To load raster data into a table, we have to use raster2pgsql driver.

In this sense, does Cloud SQL support it? Also, it would be really useful if it had out-of-db raster support considering we could store data in Cloud Storage and query it from there.

Was it helpful?

Solution

raster2pgsql

This a helper to make the job easy. It's not strictly speaking required.

raster2pgsql is a raster loader executable that loads GDAL supported raster formats into sql suitable for loading into a PostGIS raster table. It is capable of loading folders of raster files as well as creating overviews of rasters.

You can just redirect the output of raster2pgsql into a file

raster2pgsql > myFile.sql

Then run myFile.sql on Google Cloud.

Licensed under: CC-BY-SA with attribution
Not affiliated with dba.stackexchange
scroll top