From 60e22a31e9a4068f9a159bbc5ed6cef6bc9099a5 Mon Sep 17 00:00:00 2001 From: XanthosXanthopoulos Date: Fri, 18 Oct 2024 18:15:22 +0300 Subject: [PATCH] Treat WKB and WKT dimensions as strings --- libtiledbsoma/src/utils/arrow_adapter.cc | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/libtiledbsoma/src/utils/arrow_adapter.cc b/libtiledbsoma/src/utils/arrow_adapter.cc index 94d27c5a88..4aebe8af66 100644 --- a/libtiledbsoma/src/utils/arrow_adapter.cc +++ b/libtiledbsoma/src/utils/arrow_adapter.cc @@ -615,6 +615,8 @@ Dimension ArrowAdapter::_create_dim( std::shared_ptr ctx) { switch (type) { case TILEDB_STRING_ASCII: + case TILEDB_GEOM_WKB: + case TILEDB_GEOM_WKT: return Dimension::create(*ctx, name, type, nullptr, nullptr); case TILEDB_TIME_SEC: case TILEDB_TIME_MS: @@ -1073,7 +1075,8 @@ ArraySchema ArrowAdapter::tiledb_schema_from_arrow_schema( continue; } - if (ArrowAdapter::arrow_is_string_type(child->format)) { + if (ArrowAdapter::arrow_is_string_type(child->format) || + ArrowAdapter::arrow_is_binary_type(child->format)) { // In the core API: // // * domain for strings must be set as (nullptr, nullptr)