Details
Description
10.1 revision 0105bf349a...
MariaDB [test]> select ST_IsRing(ST_LineFromText('LINESTRING(0 0,0 10,10 10,0 0)'));
+--------------------------------------------------------------+
| ST_IsRing(ST_LineFromText('LINESTRING(0 0,0 10,10 10,0 0)')) |
+--------------------------------------------------------------+
| 0 |
+--------------------------------------------------------------+
PostgeSQL 9.4, PostGIS 2.1.5
pgis=# select ST_IsRing(ST_LineFromText('LINESTRING(0 0,0 10,10 10,0 0)'));
st_isring
-----------
t
(1 row)
Gliffy Diagrams
Attachments
Issue Links
- relates to
-
MDEV-7509
Testing for GIS extensions
-
- Stalled
-
Activity
- All
- Comments
- Work Log
- History
- Activity
- Transitions
IsRing is supposed to apply if IsSimple and IsClosed. In the above example, IsClosed is true, while IsSimple is false, when it seems it should be true.
select ST_IsSimple(ST_LineFromText('LINESTRING(0 0,0 10,10 10,0 0)')); +----------------------------------------------------------------+ | ST_IsSimple(ST_LineFromText('LINESTRING(0 0,0 10,10 10,0 0)')) | +----------------------------------------------------------------+ | 0 | +----------------------------------------------------------------+ select ST_IscLOSED(ST_LineFromText('LINESTRING(0 0,0 10,10 10,0 0)')); +----------------------------------------------------------------+ | ST_IscLOSED(ST_LineFromText('LINESTRING(0 0,0 10,10 10,0 0)')) | +----------------------------------------------------------------+ | 1 | +----------------------------------------------------------------+