> ## 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_BuildArea

Returns the areal geometry formed by the constituent linework of the input geometry.

<img src="https://mintcdn.com/wherobots/AayJA2u8CknIeTgt/images/sql-functions/ST_BuildArea/ST_BuildArea.svg?fit=max&auto=format&n=AayJA2u8CknIeTgt&q=85&s=80dbfcbc359f6bc588df35ccbfb6f912" alt="ST_BuildArea" width="500" height="300" data-path="images/sql-functions/ST_BuildArea/ST_BuildArea.svg" />

## Signatures

```sql theme={"system"}
ST_BuildArea (A: Geometry)
```

## Parameters

<ParamField body="A" type="Geometry" required>
  The input geometry.
</ParamField>

## Return type

<ResponseField type="Geometry">
  The resulting geometry.
</ResponseField>

## Example

```sql theme={"system"}
SELECT ST_BuildArea(
    ST_GeomFromWKT('MULTILINESTRING((0 0, 20 0, 20 20, 0 20, 0 0),(2 2, 18 2, 18 18, 2 18, 2 2))')
) AS geom
```

```

+----------------------------------------------------------------------------+
|geom                                                                        |
+----------------------------------------------------------------------------+
|POLYGON((0 0,0 20,20 20,20 0,0 0),(2 2,18 2,18 18,2 18,2 2))                |
+----------------------------------------------------------------------------+
```
