<div dir="ltr">Thanks Nyall,<div><br></div><div>Looking at the documentation it seems to be what I'm looking for.</div><div class="gmail_extra"><br clear="all"><div><div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr">Thanks,<br>
<br>
Paul<br>
<br>
<div style="font-size:13.3px;font-family:Verdana,Arial,Helvetica,sans-serif"><div style="border:1px solid #e5e5e5;background-color:#f8f8f8;padding:0.8em 0.8em 0.3em 0.8em"><div style="margin:0 0 8px 0"><p style="margin:0"><span><b><img style="float:left;margin-left:5px;margin-right:5px" src="http://www.bontepaarden.nl/bontepaarden/images/newButton.png" alt="" height="120" width="160">Paul Meems </b><br><span>Release manager, configuration manager</span><br><span>and forum moderator of MapWindow GIS.</span><br><a href="http://www.mapwindow.org/" target="_blank"><span>www.mapwindow.org</span></a><br><br><span>Owner of MapWindow.nl - Support for</span><br><span>Dutch speaking users.</span><br><a href="http://www.mapwindow.nl/" target="_blank"><span>www.mapwindow.nl</span></a><br></span></p>
<p style="margin:0px"><b><br></b></p><p style="margin:0px"><b>The MapWindow GIS project has moved to <a href="https://github.com/MapWindow" target="_blank">GitHub</a>!</b></p><p style="font-size:13.3px;margin:0px"><br><a href="https://github.com/MapWindow/MapWinGIS/releases" target="_blank">Download the latest MapWinGIS mapping engine.</a><br></p><p style="font-size:13.3px;margin:0px"><span style="font-size:13.3px"><a href="https://github.com/MapWindow/MapWindow5/releases" target="_blank">Download the latest MapWindow 5 open source desktop application.</a></span></p></div></div><img src="http://p1.wisestamp.com/pixel.png?p=mozilla&v=3.9.12&t=1322134056890&u=482737fd0c4ca423" height="1" width="1"></div>
</div></div></div></div></div></div></div></div></div>
<br><div class="gmail_quote">2017-01-05 23:24 GMT+01:00 Nyall Dawson <span dir="ltr"><<a href="mailto:nyall.dawson@gmail.com" target="_blank">nyall.dawson@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="auto"><span class=""><div><br><div class="gmail_extra"><br><div class="gmail_quote">On 6 Jan 2017 7:37 AM, "Paul Meems" <<a href="mailto:bontepaarden@gmail.com" target="_blank">bontepaarden@gmail.com</a>> wrote:<br type="attribution"><blockquote class="m_6021451402808880436quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">We're using GDAL v2.1.2 on Windows.<div><br><div>We use the GDAL library with MapWinGIS to connect to a PostGIS database.</div><div>When the PostGIS table has NULL values in integer, numeric or double fields and that data is read the returned values are 0 (zero), which is unexpected by us.</div><div><br></div><div>We use Feature->GetFieldAsDouble(<wbr>) and Feature->GetFieldAsInteger<wbr>().</div><div>Am I correct that these function return 0 when the database value is NULL?</div><div>If not our implementation is wrong and I need to continue my search.</div><div>The documentation <a href="http://www.gdal.org/classOGRFeature.html#ab8a57c94e8bb8ffac5e7048d896254b4" target="_blank">http://www.gdal.org/classOGRFe<wbr>ature.html#ab8a57c94e8bb8ffac5<wbr>e7048d896254b4</a> doesn't say either way.</div></div></div></blockquote></div></div></div><div dir="auto"><br></div></span><div dir="auto">Try Feature->IsFieldSet(...)</div><div dir="auto"><br></div><div dir="auto"><a href="http://www.gdal.org/classOGRFeature.html#a7ad01c76b7b13bcf9eab5092aacac5fb" target="_blank">http://www.gdal.org/<wbr>classOGRFeature.html#<wbr>a7ad01c76b7b13bcf9eab5092aacac<wbr>5fb</a><br></div><div dir="auto"><br></div><div dir="auto">That should return false for null values.</div><div dir="auto"><br></div><div dir="auto">Nyall</div><div dir="auto"><br></div><div dir="auto"><div class="gmail_extra"><div class="gmail_quote"><blockquote class="m_6021451402808880436quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div><br></div><div>Thanks,<div><div class="m_6021451402808880436m_-3867451395472706491gmail_signature"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr">
<br>
Paul<br>
</div></div></div></div></div></div>
</div></div></div>
<br>______________________________<wbr>_________________<br>
gdal-dev mailing list<br>
<a href="mailto:gdal-dev@lists.osgeo.org" target="_blank">gdal-dev@lists.osgeo.org</a><br>
<a href="http://lists.osgeo.org/mailman/listinfo/gdal-dev" rel="noreferrer" target="_blank">http://lists.osgeo.org/mailman<wbr>/listinfo/gdal-dev</a><br></blockquote></div><br></div></div></div>
</blockquote></div><br></div></div>