Notă
Accesul la această pagină necesită autorizare. Puteți încerca să vă conectați sau să modificați directoarele.
Accesul la această pagină necesită autorizare. Puteți încerca să modificați directoarele.
Applies to:
Databricks SQL
Databricks Runtime 17.1 and above
Important
This feature is in Public Preview. You can confirm preview enrollment on the Previews page. See Manage Azure Databricks previews.
Note
This feature is not available on Databricks SQL Classic warehouses. To learn more about Databricks SQL warehouses, see SQL warehouse types.
Returns the maximum X coordinate of the input GEOMETRY value, or NULL if the geometry is empty.
Syntax
st_xmax ( geoExpr )
Arguments
geoExpr: AGEOMETRYvalue.
Returns
A value of type DOUBLE, equal to the maximum X coordinate of the input GEOMETRY value.
The function returns NULL if the input is NULL or if the geometry is empty.
Examples
-- Returns the maximum X coordinate of a non-empty geometry.
> SELECT st_xmax(st_geomfromtext('LINESTRING(10 34,44 57,30 24)'));
44.0
-- Returns `NULL` for an empty geometry.
> SELECT st_xmax(st_geomfromtext('POLYGON EMPTY'));
NULL