<div dir="ltr">Hi,<div><br></div><div>In plpgsql, you can catch the error that will be generated by such a polygon:</div><div><br></div><div><a href="http://www.postgresql.org/docs/9.5/static/plpgsql-control-structures.html#PLPGSQL-ERROR-TRAPPING">http://www.postgresql.org/docs/9.5/static/plpgsql-control-structures.html#PLPGSQL-ERROR-TRAPPING</a></div><div><br></div><div>NicolasĀ </div></div><div class="gmail_extra"><br><div class="gmail_quote">On 15 February 2016 at 15:43, LPlateAndy <span dir="ltr"><<a href="mailto:andy@centremaps.co.uk" target="_blank">andy@centremaps.co.uk</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi,<br>
<br>
I have a postgresql trigger function which creates a geometry from WKT<br>
before data in inserted into the table. Saves on temp tables or on loading<br>
and then updating.<br>
<br>
Is there a way (possibly a plpgsql not postgis question) to ignore (treat as<br>
NULL) a bum geometry - e.g a polygon with a single point<br>
<br>
Andy<br>
<br>
<br>
<br>
--<br>
View this message in context: <a href="http://postgis.17.x6.nabble.com/handling-invalid-geometry-within-a-trigger-tp5009691.html" rel="noreferrer" target="_blank">http://postgis.17.x6.nabble.com/handling-invalid-geometry-within-a-trigger-tp5009691.html</a><br>
Sent from the PostGIS - User mailing list archive at Nabble.com.<br>
_______________________________________________<br>
postgis-users mailing list<br>
<a href="mailto:postgis-users@lists.osgeo.org">postgis-users@lists.osgeo.org</a><br>
<a href="http://lists.osgeo.org/mailman/listinfo/postgis-users" rel="noreferrer" target="_blank">http://lists.osgeo.org/mailman/listinfo/postgis-users</a></blockquote></div><br></div>