<div dir="ltr"><div><div><div><div>I was looking at this page today:<br><br><a href="http://postgis.refractions.net/docs/using_postgis_dbmanagement.html#OGC_Validity">http://postgis.refractions.net/docs/using_postgis_dbmanagement.html#OGC_Validity</a><br>
<br></div>This is a wonderfully simple explanation of what constitutes validity and simplicity with regards to geometries. However, I noted that this page doesn't seem to address problems with POLYGONs like when the exterior ring is self intersecting. For example, this query:<br>
<br>SELECT ST_IsValidDetail(ST_GeomFromText('POLYGON((0 1,1 1,1 0,-1 0,-1 -1,0 -1,0 1))'));<br><br></div>correctly yields<br><br>(f,Self-intersection,010100000000000000000000000000000000000000)<br><br></div>Maybe I'm missing something in the documentation, but I don't see anything that directly indicates that this would be considered invalid. Maybe it's assumed that this would not be considered a POLYGON at all since a POLYGON must be simple? I'm not really sure. I think some kind of clarification is in order regardless of what kind. It seems that polygon rings must adhere to the simplicity requirements for line strings. Maybe that could be mentioned?<br>
<br></div><div>Thanks for PostGIS and its documentation. Easily my favorite spatial database thus far.<br></div></div>