ST_Within

E427698

ST_Within is a PostGIS spatial function that tests whether one geometry is completely contained within another, returning a boolean result.

All labels observed (1)

Label Occurrences
ST_Within canonical 1

How this entity was disambiguated

Statements (41)

Predicate Object
instanceOf PostGIS spatial function
geometry relationship function
topological predicate
acceptsArgumentType geometry
geometry collection
argumentCount 2
availableIn PostgreSQL with PostGIS extension NERFINISHED
basedOnModel DE-9IM
compliesWith OGC Simple Features specification semantics
documentationURL https://postgis.net/docs/ST_Within.html
exampleUsage SELECT ST_Within(geom, boundary_geom) FROM mytable;
falseWhen any point of g1 lies in the exterior of g2
geometries are disjoint
geometries only touch at boundary without interior inclusion
firstArgumentRole inner geometry
geometryDimensionSupport supports linestrings
supports points
supports polygons
implementedIn PostGIS NERFINISHED
indexSupport can use spatial indexes for performance
isInverseOf ST_Contains
libraryDependency GEOS NERFINISHED
nullHandling returns NULL if any input geometry is NULL
relatedFunction ST_ContainsProperly
ST_CoveredBy
ST_Covers
ST_Intersects
ST_Within(geography)
returns boolean
secondArgumentRole outer geometry
sqlSignature ST_Within(geometry g1, geometry g2) → boolean
testsProperty boundary of inner geometry does not intersect exterior of outer geometry
no points of inner geometry lie in exterior of outer geometry
one geometry is completely inside another geometry
testsRelation within
trueWhen every point of g1 is in the interior or boundary of g2
usedFor filtering geometries contained in other geometries
finding features inside administrative boundaries
point-in-polygon tests
spatial queries
usesAlgorithm Dimensionally Extended nine-Intersection Model NERFINISHED

How these facts were elicited

Referenced by (1)

Full triples — surface form annotated when it differs from this entity's canonical label.

PostGIS supportsOperation ST_Within