ST_ExpandSpatial

更新时间:
复制 MD 格式

Expands a bounding box to a specified spatial scope. If the bounding box has the x, y, and z dimensions, the lower bound is decreased by the value of the len parameter, and the upper bound is increased by the value of the len parameter.

Syntax

boxndf ST_ExpandSpatial(boxndf box, float8 len);

Parameters

ParameterDescription
boxThe bounding box to expand.
lenThe expansion distance. If the bounding box has the x, y, and z dimensions, each lower bound is decreased by this value, and each upper bound is increased by this value.

Example

SELECT ST_ExpandSpatial(ST_MakeBox2dt(0,0,'2000-01-02', 20,20, '2000-03-03'), 4);
                      st_expandspatial
-------------------------------------------------------------
 BOX2DT(-4 -4 2000-01-02 00:00:00,24 24 2000-03-03 00:00:00)