duckdb_spatial icon indicating copy to clipboard operation
duckdb_spatial copied to clipboard

Register GeoArrow extensions by default

Open kylebarron opened this issue 6 months ago • 1 comments

I was looking at how to get GeoArrow extension metadata on Arrow types exported to Python and I learned from @paleolimbot that I needed CALL register_geoarrow_extensions() to apply the GeoArrow metadata onto exported data.

Would it be possible to register those extensions by default? I imagine not everyone knows they exist.

kylebarron avatar May 29 '25 21:05 kylebarron

We're getting a native geometry type in DuckDB v1.5 so this won't be necessary anymore then!

Maxxen avatar Oct 24 '25 10:10 Maxxen

The current ArrowConverter implementation with the new logical type is still not working. Using the new arrow c-api (duckdb_to_arrow_schema, duckdb_schema_from_arrow) still defines the duckdb geometry as binary data with out extension metadata in the arrow and binary arrow data with extensions metadata (geoarrow.wkb) as blob.

VGSML avatar Nov 27 '25 12:11 VGSML

I think thats a problem with the C-API, I will have a look at it before 1.5 eventually.

Maxxen avatar Nov 27 '25 13:11 Maxxen

I got the same results when I tried to pass a table with geometry columns through the airport extension, so it is somewhere in the arrow_converter (ArrowConverter)

VGSML avatar Nov 27 '25 14:11 VGSML

I'm just going to watch this thread, once it is ready to go, I'll happily add the GEOMETRY type to the list of DuckDB types tested in the Airport CI test suite.

rustyconover avatar Nov 28 '25 15:11 rustyconover