handstuyennn / geo

116 stars 7 forks source link

No enum constant org.duckdb.DuckDBColumnType.GEOGRAPHY #20

Open ScottMeads opened 1 year ago

ScottMeads commented 1 year ago

I might be missing something simple, but couldn't find anything online. When calling ST_MAKEPOINT I receive the error below:

No enum constant org.duckdb.DuckDBColumnType.GEOGRAPHY

I'm using DuckDB 0.7.0, compiling on an M1 Mac.

Mause commented 1 year ago

You haven't missed anything, the support for complex types in the DuckDB JDBC driver is still a work in progress.

I've done some work, https://github.com/duckdb/duckdb/pull/7000, to auto-stringify types that aren't explicitly handled, including extension types, which should improve things

In the meantime, you can explicitly cast the GEOGRAPHY type to a string by doing

SELECT geo_column::varchar FROM table