[postgis-users] How to re-tile a raster after union ?

Francois Hugues hugues.francois at irstea.fr
Wed Oct 31 12:59:54 PDT 2012


Hi,

I have a tiled dem which I want to use to calculate slopes. If I want to avoid the border effect between each tile, I have to use st_union (the faster version, thanks to P. Racine).

But, if I'm not wrong, I will obtain a single tile raster. The answer to my question is maybe so obvious that I can't see it, but how can I re-tile my raster in a new table. Is there no other way to tile than to use raster2pgsql ? I'm surprised that there is no postgis function for that so I think I may miss something.

Thanks for your answer and advices !

Hugues.

PS : I'm trying to clip my raster to reduce time, but I have a problem with ST_Clip. After little googling, I saw that few people had this error but I did not find the solution. Does an upgrade should solve this issue ?

ERROR:  rt_raster_gdal_rasterize: Unable to add band to GDALDataset
CONTEXT:  PL/pgSQL function "st_asraster" line 26 at RETURN PL/pgSQL function "st_clip" line 36 at assignment

"POSTGIS="2.0.0 r9605" GEOS="3.3.2-CAPI-1.7.2" PROJ="Rel. 4.8.0, 6 March 2012" GDAL="GDAL 1.9.0, released 2011/12/29" LIBXML="2.7.8" LIBJSON="UNKNOWN" (core procs from "2.0.0rc1 r9576" need upgrade) TOPOLOGY (topology procs from "2.0.0rc1 r9576" need upgrade) RASTER (raster procs from "2.0.0rc1 r9576" need upgrade)"

-- 
Hugues FRANÇOIS 
Ingénieur recherche 

Irstea Grenoble 
2 rue de la papeterie 
38400 Saint-Martin d'Hères 

tel : +33 (0)4.76.76.27.44 
port : +33 (0)6.77.66.21.31 
fax : +33 (0)4.76.51.38.03
 



More information about the postgis-users mailing list