Description
The ST_X function returns the X ordinate of the geometry if the geometry
is a point, or Null if the geometry is not a point or is null.
Function Registration
create function ST_X as 'com.pb.bigdata.spatial.hive.observer.ST_X';
Syntax
ST_X(WritableGeometry geometry)
Parameters
| Parameter |
Type |
Description |
| geometry |
WritableGeometry |
The input geometry. |
Return Values
| Return Type |
Description |
| Double |
The X ordinate of the geometry if the geometry is a point, or Null if the geometry is
not a point or is null. |
Examples
SELECT ST_X(ST_Point(x, y, 'epsg:4326')) FROM src;