ST_POINTN (Lakehouse v1)
Renvoie le Point situé à un index donné dans un LineString.
Syntaxe SQL
Section intitulée « Syntaxe SQL »ST_POINTN(<geometry>, <index>)Arguments
Section intitulée « Arguments »| Arguments | Description |
|---|---|
<geometry> |
L’argument doit être une expression de type GEOMETRY qui représente un LineString. |
<index> |
L’index du Point à renvoyer. |
Type de retour
Section intitulée « Type de retour »Geometry.
Exemples SQL
Section intitulée « Exemples SQL »SELECT ST_POINTN( ST_GEOMETRYFROMWKT( 'LINESTRING(1 1, 2 2, 3 3, 4 4)' ), 1 ) AS pipeline_pointn;
┌─────────────────┐│ pipeline_pointn │├─────────────────┤│ POINT(1 1) │└─────────────────┘
SELECT ST_POINTN( ST_GEOMETRYFROMWKT( 'LINESTRING(1 1, 2 2, 3 3, 4 4)' ), -2 ) AS pipeline_pointn;
┌─────────────────┐│ pipeline_pointn │├─────────────────┤│ POINT(3 3) │└─────────────────┘