Returns the upper-left X coordinate of a raster object in the spatial reference system.
Prerequisites
Before you call this function, ensure that the raster object has a valid spatial reference system identifier (SRID).
Syntax
float8 ST_UpperLeftX(raster raster_obj)Parameters
| Parameter | Description |
|---|---|
raster_obj | The raster object to query. |
Examples
Query the upper-left X and Y coordinates for all rasters in a table:
SELECT ST_UpperLeftX(rast) AS ulx, ST_UpperLeftY(rast) AS uly
FROM raster_table;Output:
ulx | uly
---------+---------
440720 | 3751320See also
ST_UpperLeftY— Returns the upper-left Y coordinate of a raster object.