ST_PointZ

ST_PointZ takes three numeric columns or double values and returns a point column. The three numeric columns or values must contain the x,y,z coordinates of the point geometries. You can optionally specify a spatial reference ID for the result point column. The sr parameter value must be a valid SRID or WKT string.

To create point geometries without m-values or z-coordinates use ST_Point. To create point geometries with m-values use ST_PointM, ST_PointZM, or ST_MakePoint.

FunctionSyntax
Pythonpoint_z(x, y, z, sr=None)
SQLST_PointZ(x, y, z, sr=None)
ScalapointZ(x, y, z, sr)

For more details, go to the GeoAnalytics for Microsoft Fabric API reference for point_z.

Examples

PythonPythonSQLScala
Use dark colors for code blocksCopy
1
2
3
4
5
6
7
from geoanalytics_fabric.sql import functions as ST

df = spark.createDataFrame([(-178.0, -17.0, 10)], ["longitude", "latitude", "z"])

df.select(ST.point_z("longitude","latitude","z", sr=4326).alias("point_z")).show(truncate=False)
Result
Use dark colors for code blocksCopy
1
2
3
4
5
+-------------------------+
|point_z                  |
+-------------------------+
|{"x":-178,"y":-17,"z":10}|
+-------------------------+

Version table

ReleaseNotes

1.0.0-beta

Python, SQL, and Scala functions introduced

Your browser is no longer supported. Please upgrade your browser for the best experience. See our browser deprecation post for more details.