Raster as a primitive type
Besides the primitive types supported by Apache Iceberg, Havasu introduced a new data typeraster to represent raster data. For instance, user can create a table with a raster column using SQL:
- Python
- Scala
- Java
rast. We can inspect the table schema using DESCRIBE command:
- Python
- Scala
- Java
.printSchema() function:
- Python
- Scala
- Java
Creating table with raster column
As mentioned above, user can create a Havasu table using SQL:- Python
- Scala
- Java
- Python
- Scala
- Java
Writing data
Writing DataFrame to Havasu table
Users can write a DataFrame containing geometry data to a Havasu table:- Python
- Scala
- Java
ACID Transactions
Havasu supports all table update statements supported by Apache Iceberg, such asUPDATE, DELETE and MERGE INTO.
The syntax is identical to the open source Apache Iceberg, please refer to Apache Iceberg - Write with SQL for more information.
Querying data
User can load data from a Havasu table usingsedona.table(...):
- Python
- Scala
- Java
- Python
- Scala
- Java
- Python
- Scala
- Java
- Python
- Scala
- Java
.format("havasu.iceberg"), this will load an isolated table reference that will not automatically refresh tables used by queries.
- Python
- Scala
- Java
Working with raster data
Data in columns withraster type will be loaded as RasterUDT values in Sedona, user can use any RS_ functions provided by WherobotsDB to manipulate the raster data. For example, user can use RS_MapAlgebra to create a new raster by applying a map algebra expression to the raster column:
- Python
- Scala
- Java
- Python
- Scala
- Java
writeTo function on the resulting DataFrame of the query:
- Python
- Scala
- Java

