Skip to content
🌵SedonaDB (Rust) 0.3.0 is out now, featuring larger-than-memory spatial joins, and row-level CRS!

RS_AsArcGrid

Introduction: Returns a binary value (byte array) representing an ArcGrid image for each input raster. ArcGrid only supports a single band. If your raster has multiple bands, you need to specify which band to use as the source.

Possible values for sourceBand: any non-negative value (>=0). If not given, it will use Band 0.

Format:

RS_AsArcGrid(raster: Raster)

RS_AsArcGrid(raster: Raster, sourceBand: Integer)

Return type: Binary

Since: v1.4.1

SQL Example

SELECT RS_AsArcGrid(raster) FROM my_raster_table

SQL Example

SELECT RS_AsArcGrid(raster, 1) FROM my_raster_table

Output:

+--------------------+
|             arcgrid|
+--------------------+
|[4D 4D 00 2A 00 0...|
+--------------------+

Output schema:

root
 |-- arcgrid: binary (nullable = true)