> ## Documentation Index
> Fetch the complete documentation index at: https://docs.wherobots.com/llms.txt
> Use this file to discover all available pages before exploring further.

# ST_MakeLine (Python)

> Creates a LineString containing the points of Point, MultiPoint, or LineString geometries.

Creates a LineString containing the points of Point, MultiPoint, or LineString geometries. Other geometry types cause an error.

SQL reference: [`ST_MakeLine`](/reference/wherobots-db/geometry-data/editors/ST_MakeLine)

## Signature

```python theme={"system"}
from sedona.spark.sql.st_functions import ST_MakeLine

ST_MakeLine(geom1: ColumnOrName, geom2: Optional[ColumnOrName] = None) -> Column
```

## Parameters

<ParamField path="geom1" type="ColumnOrName" required>
  Geometry column to convert.
</ParamField>

<ParamField path="geom2" type="Optional[ColumnOrName]" default="None">
  Geometry column to convert. If geoms is empty, then geom1 is an array of geometries.
</ParamField>

## Returns

<ResponseField name="return" type="Column">
  LineString geometry column created from the input geometries.
</ResponseField>


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.