<div dir="ltr"><div><div>Hey,<br></div>what is your version of gdal (type `gdalinfo --version`)<br></div>Cheers,<br>Rémi-C<br></div><div class="gmail_extra"><br><br><div class="gmail_quote">2014-05-16 11:14 GMT+02:00 Blumentrath, Stefan <span dir="ltr"><<a href="mailto:Stefan.Blumentrath@nina.no" target="_blank">Stefan.Blumentrath@nina.no</a>></span>:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div link="blue" vlink="purple" lang="NO-BOK">
<div>
<p class="MsoNormal"><span lang="EN-US">Hi,<u></u><u></u></span></p>
<p class="MsoNormal"><span lang="EN-US"><u></u> <u></u></span></p>
<p class="MsoNormal"><span lang="EN-US">And sorry for posting on two lists. Just don`t know where the issue belongs to…<u></u><u></u></span></p>
<p class="MsoNormal"><span lang="EN-US"><br>
I tried to load a set of raster maps in Geotiff format, which I created in GRASS using r.external.out, into PostGIS 2.1.2dev.<u></u><u></u></span></p>
<p class="MsoNormal"><span lang="EN-US"><u></u> <u></u></span></p>
<p class="MsoNormal"><span lang="EN-US">In PostGIS the raster datasets only contain NoData values, while gdalinfo –stats produces reasonable statistics for the respective GeoTiffs.<u></u><u></u></span></p>
<p class="MsoNormal"><span lang="EN-US"><u></u> <u></u></span></p>
<p class="MsoNormal"><span lang="EN-US">I did some trouble shooting and found that the problem was that GRASS did not assign a numerical NoData value to the GeoTiff, but “nan”.<u></u><u></u></span></p>
<p class="MsoNormal"><span lang="EN-US"><u></u> <u></u></span></p>
<p class="MsoNormal"><span lang="EN-US">When I gdal_translate same GeoTiff with –a_nodata -9999, raster2pgsql loads the resulting file just fine.<u></u><u></u></span></p>
<p class="MsoNormal"><span lang="EN-US"><u></u> <u></u></span></p>
<p class="MsoNormal"><span lang="EN-US">Is raster2pgsql supposed to read rasters with nan as NoData values (using –N -9999 in raster2pgsql had no effect btw.) or should GRASS (r.external.out) assign a NoData value to the produced raster datasets?<u></u><u></u></span></p>
<p class="MsoNormal"><span lang="EN-US"><u></u> <u></u></span></p>
<p class="MsoNormal"><span lang="EN-US">Many thanks in advance,<u></u><u></u></span></p>
<p class="MsoNormal"><span lang="EN-US">Stefan <u></u><u></u></span></p>
<p class="MsoNormal"><span lang="EN-US"><u></u> <u></u></span></p>
<p class="MsoNormal"><span lang="EN-US"><u></u> <u></u></span></p>
</div>
</div>
<br>_______________________________________________<br>
grass-dev mailing list<br>
<a href="mailto:grass-dev@lists.osgeo.org">grass-dev@lists.osgeo.org</a><br>
<a href="http://lists.osgeo.org/mailman/listinfo/grass-dev" target="_blank">http://lists.osgeo.org/mailman/listinfo/grass-dev</a><br></blockquote></div><br></div>