Skip to content

metadata(csharp): Thrift GetColumns throws NotSupportedException on GEOMETRY/GEOGRAPHY columns #568

Closed

Description

@eric-wang-1990

Problem

GetColumns (and list_columns) on the Thrift path throws NotSupportedException when a table contains a GEOMETRY or GEOGRAPHY column, because the SQL type-name parser has no entry for these types and no catch-all.

Call path:

  • SparkConnection.SetPrecisionScaleAndTypeName is invoked per column during GetColumns; the default arm (csharp/hiveserver2/csharp/src/AdbcDrivers.HiveServer2/Spark/SparkConnection.cs:113-120) calls SqlTypeNameParser<…>.Parse(typeName, colType).
  • SqlTypeNameParser.Parse throws NotSupportedException($"Unsupported SQL type name: '{input}'") when no registered parser matches (.../Hive2/SqlTypeNameParser.cs:119-122).
  • The registered parser set (SqlTypeNameParser.cs:54-101) has no GEOMETRY/GEOGRAPHY entry, and the only "simple" parser matches an exact literal base name (^\s*<name>\s*$) with no catch-all. A repo-wide grep for GEOMETRY|GEOGRAPHY finds zero handling in the driver.

Result: metadata discovery crashes outright on any table with a geospatial column.

Note on related work

This is distinct from the GeoArrow data-path work (#339, #340, #361, PR #350), which converts geometry values to geoarrow.wkb. Those do not touch the SqlTypeNameParser metadata path — a table with a geometry column still throws in GetColumns regardless.

Comparator reference: D11 in the ADBC SEA Public Preview plan ("Thrift's list_columns can't parse GEOMETRY (and GEOGRAPHY) types; throws on wildcard column patterns"). The wildcard-column-pattern throw noted in D11 should be verified as part of this issue too.

Expected

GetColumns/list_columns should return a row for GEOMETRY/GEOGRAPHY columns (mapping to a reasonable ADBC/Arrow type) rather than throwing.

Activity

  1. added
    bugSomething isn't working
    .NETPull requests that update .NET code
    engineer-botengineer-bot may fix this issue / take over this PR
    on Jul 7, 2026
  2. peco-engineer-bot commented on Jul 8, 2026

    @peco-engineer-bot
    Contributor

    🤖 engineer-bot is on it — working on a fix. Progress: run log. I'll comment again with the outcome (and open a fix PR if I make changes).

  3. peco-engineer-bot commented on Jul 8, 2026

    @peco-engineer-bot
    Contributor

    engineer-bot bug-fix: outcome=success. Fix PR: #578.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    .NETPull requests that update .NET codebugSomething isn't workingengineer-botengineer-bot may fix this issue / take over this PR

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions