All Products
Search
Document Center

ApsaraDB RDS:ST_LineToCurve

Last Updated:Sep 04, 2023

This topic describes the ST_LineToCurve function. This function converts a LineString or polygon object into a CircularString or Curved Polygon object.

Syntax

geometry  ST_LineToCurve(geometry  geomANoncircular);

Parameters

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

Description

  • The points that are required to represent the equivalent curves are much fewer than the input LineString or polygon object.
  • If the input LineString or polygon object is not curved enough to clearly represent a curve, the function returns the input geometry object.

Examples

Results returned by using the default parameter settings:
SELECT ST_AsText(ST_LineToCurve(ST_Buffer('POINT(0 0)', 1)));
                 st_astext
--------------------------------------------
 CURVEPOLYGON(CIRCULARSTRING(1 0,-1 0,1 0))
(1 row)