This topic describes the ST_Multi function. This function returns a MULTI geometry object that corresponds to the input geometry object.

Syntax

geometry  ST_Multi(geometry  g1);

Parameters

Parameter Description
g1 The geometry object that you want to specify.

Description

If the input geometry object is a MULTI geometry object, the ST_Multi function returns the original geometry object.

Examples

SELECT ST_AsText(ST_Multi(ST_GeomFromText('LINESTRING(1 1,2 1)')));
         st_astext
----------------------------
 MULTILINESTRING((1 1,2 1))
(1 row)