Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[DOCS] Reorder Constructor page #1330

Merged
merged 1 commit into from
Apr 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
188 changes: 94 additions & 94 deletions docs/api/flink/Constructor.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,52 @@
## ST_GeomFromEWKT

Introduction: Construct a Geometry from OGC Extended WKT

Format:
`ST_GeomFromEWKT (EWkt: String)`

Since: `v1.5.0`

Example:
```sql
SELECT ST_AsText(ST_GeomFromEWKT('SRID=4269;POINT(40.7128 -74.0060)'))
```

Output:

```
POINT(40.7128 -74.006)
```

## ST_GeomFromGML

Introduction: Construct a Geometry from GML.

Format:
`ST_GeomFromGML (gml: String)`

Since: `v1.3.0`

Example:

```sql
SELECT ST_GeomFromGML('
<gml:LineString srsName="EPSG:4269">
<gml:coordinates>
-71.16028,42.258729
-71.160837,42.259112
-71.161143,42.25932
</gml:coordinates>
</gml:LineString>
')
```

Output:

```
LINESTRING (-71.16028 42.258729, -71.160837 42.259112, -71.161143 42.25932)
```

## ST_GeomFromGeoHash

Introduction: Create Geometry from geohash string and optional precision
Expand Down Expand Up @@ -87,35 +136,6 @@ Output:
POLYGON ((-87.621765 34.873444, -87.617535 34.873369, -87.62119 34.85053, -87.62144 34.865379, -87.621765 34.873444))
```

## ST_GeomFromGML

Introduction: Construct a Geometry from GML.

Format:
`ST_GeomFromGML (gml: String)`

Since: `v1.3.0`

Example:

```sql
SELECT ST_GeomFromGML('
<gml:LineString srsName="EPSG:4269">
<gml:coordinates>
-71.16028,42.258729
-71.160837,42.259112
-71.161143,42.25932
</gml:coordinates>
</gml:LineString>
')
```

Output:

```
LINESTRING (-71.16028 42.258729, -71.160837 42.259112, -71.161143 42.25932)
```

## ST_GeomFromKML

Introduction: Construct a Geometry from KML.
Expand Down Expand Up @@ -232,26 +252,6 @@ Output:
POINT(40.7128 -74.006)
```

## ST_GeomFromEWKT

Introduction: Construct a Geometry from OGC Extended WKT

Format:
`ST_GeomFromEWKT (EWkt: String)`

Since: `v1.5.0`

Example:
```sql
SELECT ST_AsText(ST_GeomFromEWKT('SRID=4269;POINT(40.7128 -74.0060)'))
```

Output:

```
POINT(40.7128 -74.006)
```

## ST_LineFromText

Introduction: Construct a LineString from Text
Expand Down Expand Up @@ -291,88 +291,88 @@ Output:
LINESTRING (-74.0428197 40.6867969, -74.0421975 40.6921336, -74.050802 40.6912794)
```

## ST_MakePoint
## ST_MLineFromText

Introduction: Creates a 2D, 3D Z or 4D ZM Point geometry. Use ST_MakePointM to make points with XYM coordinates. Z and M values are optional.
Introduction: Construct a MultiLineString from Text and Optional SRID

Format: `ST_MakePoint (X: Double, Y: Double, Z: Double, M: Double)`
Format: `ST_MLineFromText (Text: String, Srid: Integer)`

Since: `v1.5.0`
Since: `1.3.1`

Example:

```sql
SELECT ST_AsText(ST_MakePoint(1.2345, 2.3456));
SELECT ST_MLineFromText('MULTILINESTRING((1 2, 3 4), (4 5, 6 7))')
```

Output:

```
POINT (1.2345 2.3456)
MULTILINESTRING ((1 2, 3 4), (4 5, 6 7))
```

Example:
## ST_MPolyFromText

```sql
SELECT ST_AsText(ST_MakePoint(1.2345, 2.3456, 3.4567));
```
Introduction: Construct a MultiPolygon from Text and Optional SRID

Output:
Format: `ST_MPolyFromText (Text: String, Srid: Integer)`

```
POINT Z (1.2345 2.3456 3.4567)
```
Since: `1.3.1`

Example:

```sql
SELECT ST_AsText(ST_MakePoint(1.2345, 2.3456, 3.4567, 4));
SELECT ST_MPolyFromText('MULTIPOLYGON(((0 0 1,20 0 1,20 20 1,0 20 1,0 0 1),(5 5 3,5 7 3,7 7 3,7 5 3,5 5 3)))')
```

Output:

```
POINT ZM (1.2345 2.3456 3.4567 4)
MULTIPOLYGON (((0 0, 20 0, 20 20, 0 20, 0 0), (5 5, 5 7, 7 7, 7 5, 5 5)))
```

## ST_MLineFromText
## ST_MakePoint

Introduction: Construct a MultiLineString from Text and Optional SRID
Introduction: Creates a 2D, 3D Z or 4D ZM Point geometry. Use ST_MakePointM to make points with XYM coordinates. Z and M values are optional.

Format: `ST_MLineFromText (Text: String, Srid: Integer)`
Format: `ST_MakePoint (X: Double, Y: Double, Z: Double, M: Double)`

Since: `1.3.1`
Since: `v1.5.0`

Example:

```sql
SELECT ST_MLineFromText('MULTILINESTRING((1 2, 3 4), (4 5, 6 7))')
SELECT ST_AsText(ST_MakePoint(1.2345, 2.3456));
```

Output:

```
MULTILINESTRING ((1 2, 3 4), (4 5, 6 7))
POINT (1.2345 2.3456)
```

## ST_MPolyFromText
Example:

Introduction: Construct a MultiPolygon from Text and Optional SRID
```sql
SELECT ST_AsText(ST_MakePoint(1.2345, 2.3456, 3.4567));
```

Format: `ST_MPolyFromText (Text: String, Srid: Integer)`
Output:

Since: `1.3.1`
```
POINT Z (1.2345 2.3456 3.4567)
```

Example:

```sql
SELECT ST_MPolyFromText('MULTIPOLYGON(((0 0 1,20 0 1,20 20 1,0 20 1,0 0 1),(5 5 3,5 7 3,7 7 3,7 5 3,5 5 3)))')
SELECT ST_AsText(ST_MakePoint(1.2345, 2.3456, 3.4567, 4));
```

Output:

```
MULTIPOLYGON (((0 0, 20 0, 20 20, 0 20, 0 0), (5 5, 5 7, 7 7, 7 5, 5 5)))
POINT ZM (1.2345 2.3456 3.4567 4)
```

## ST_Point
Expand All @@ -395,49 +395,49 @@ Output:
POINT (1.2345 2.3456)
```

## ST_PointZ

Introduction: Construct a Point from X, Y and Z and an optional srid. If srid is not set, it defaults to 0 (unknown).
Must use ST_AsEWKT function to print the Z coordinate.

Format:
## ST_PointFromText

`ST_PointZ (X: Double, Y: Double, Z: Double)`
Introduction: Construct a Point from Text, delimited by Delimiter

`ST_PointZ (X: Double, Y: Double, Z: Double, srid: Integer)`
Format: `ST_PointFromText (Text: String, Delimiter: Char)`

Since: `v1.5.0`
Since: `v1.2.0`

Example:

```sql
SELECT ST_AsEWKT(ST_PointZ(1.2345, 2.3456, 3.4567))
SELECT ST_PointFromText('40.7128,-74.0060', ',')
```

Output:

```
POINT Z(1.2345 2.3456 3.4567)
POINT (40.7128 -74.006)
```

## ST_PointFromText
## ST_PointZ

Introduction: Construct a Point from Text, delimited by Delimiter
Introduction: Construct a Point from X, Y and Z and an optional srid. If srid is not set, it defaults to 0 (unknown).
Must use ST_AsEWKT function to print the Z coordinate.

Format: `ST_PointFromText (Text: String, Delimiter: Char)`
Format:

Since: `v1.2.0`
`ST_PointZ (X: Double, Y: Double, Z: Double)`

`ST_PointZ (X: Double, Y: Double, Z: Double, srid: Integer)`

Since: `v1.5.0`

Example:

```sql
SELECT ST_PointFromText('40.7128,-74.0060', ',')
SELECT ST_AsEWKT(ST_PointZ(1.2345, 2.3456, 3.4567))
```

Output:

```
POINT (40.7128 -74.006)
POINT Z(1.2345 2.3456 3.4567)
```

## ST_PolygonFromEnvelope
Expand Down
Loading
Loading