Skip to main content
Cover the geometry with Google S2 Cells, return the corresponding cell IDs with the given level. The level indicates the size of cells. With a bigger level, the cells will be smaller, the coverage will be more accurate, but the result size will be exponentially increasing.

Signatures

Parameters

geom
Geometry
required
The input geometry.
level
Integer
required
The level value.

Return type

An integer value.

Example

ST_S2CellIDs