Tests whether geography A fully contains geography B using S2 spherical boolean operations. Returns true if every point of B is inside or on the boundary of A.
Signatures
ST_Contains (A: Geography, B: Geography)
Parameters
The containing geography.
The geography tested for containment within A.
Return type
true if A fully contains B.
Example
SELECT ST_Contains(
ST_GeogFromWKT('POLYGON ((0 0, 1 0, 1 1, 0 1, 0 0))'),
ST_GeogFromWKT('POINT (0.5 0.5)')
);