You need the following in place before you can proceed with the steps required for the recipe:
- You need to have gone through the previous recipe and imported tmax 2012 datasets (12 .bil files) as a single multiband (12 bands) raster in PostGIS.
- You must have the PostGIS raster format enabled in GDAL. For this purpose, check the output of the following command:
$ gdalinfo --formats | grep -i postgis
The output of the preceding command is as follows:
PostGISRaster (rw): PostGIS Raster driver
- You should have already learned how to use the GDAL PostGIS raster driver in the previous two recipes. You need to use a connection string composed of the following parameters:
$ gdalinfo PG:"host=localhost port=5432
dbname='postgis_cookbook' user='me' password='mypassword'
schema='chp01' table='tmax_2012_multi' mode='2'"
- Refer to the previous two recipes for more information about the preceding parameters.