ST_MemSize

Signature

DOUBLE ST_MemSize(GEOMETRY geom);

Description

Returns the amount of memory space (in bytes) taken by the geometry geom.

Warning

ST_MemSize only support geometry value

Examples

SELECT ST_MemSize('MULTIPOLYGON(((2 1, 1 2, 2 2, 2 3, 3 3, 3 2, 4 2, 4 1, 3 0, 2 0, 2 1)), 
                                ((1 3, 0 4, 3 4, 1 3.5, 1 3)))'::GEOMETRY);
-- Answer: 291

See also