

 Amazon Redshift は、パッチ 198 以降、新しい Python UDF の作成をサポートしなくなります。既存の Python UDF は、2026 年 6 月 30 日まで引き続き機能します。詳細については、[ブログ記事](https://aws.amazon.com/blogs/big-data/amazon-redshift-python-user-defined-functions-will-reach-end-of-support-after-june-30-2026/)を参照してください。

# ST\$1M
<a name="ST_M-function"></a>

ST\$1M は、入力ポイントの `m` 座標を返します。

## 構文
<a name="ST_M-function-syntax"></a>

```
ST_M(point)
```

## 引数
<a name="ST_M-function-arguments"></a>

 *point*   
データ型 `POINT` の `GEOMETRY` 値。

## 戻り型
<a name="ST_M-function-return"></a>

`m` 座標系の `DOUBLE PRECISION` 値。

*point* が null の場合、null が返されます。

*point* が 2D または 3DZ ポイントの場合、null が返されます。

*point* が空のポイントの場合、null が返されます。

*point* が `POINT` でない場合、エラーが返されます。

## 例
<a name="ST_M-function-examples"></a>

次の SQL は、ポイントの `m` 座標を、3DM ジオメトリで返します。

```
SELECT ST_M(ST_GeomFromEWKT('POINT M (1 2 3)'));
```

```
st_m
-----------
 3
```

次の SQL は、1 つのポイントの `m` 座標を、4D ジオメトリで返します。

```
SELECT ST_M(ST_GeomFromEWKT('POINT ZM (1 2 3 4)'));
```

```
st_m
-----------
 4
```