Inside
INSIDE(g1 Geometry, g2 Geometry)
Alias: ST_INSIDE
Returns 1 if every point in g1 is shared with g2; returns 0 otherwise. Returns the same result as WITHIN.
Result type: integer
Examples:
SELECT INSIDE(POLYFROMTEXT('POLYGON((0 0, 0 10, 10 10, 10 0, 0 0))'), POLYFROMTEXT('POLYGON((0 0, 0 10, 10 10, 0 0))'));
-------------
col1
-------------
0
-------------
SELECT INSIDE(POINTFROMTEXT('POINT(2 8)'), POLYFROMTEXT('POLYGON((0 0, 0 10, 10 10, 0 0))'));
-------------
col1
-------------
1
-------------
Last modified date: 08/28/2024