{"record":{"id":"5463b0352e17cf4f","repo":"apache/seatunnel","slug":"common-17-5463b0","errorCode":"COMMON-17","errorMessage":"'<identifier>' unsupported convert type '<dataType>' of '<field>' to SeaTunnel data type.","messagePattern":"'<identifier>' unsupported convert type '<dataType>' of '<field>' to SeaTunnel data type\\.","errorType":"error_code","errorClass":"org.apache.seatunnel.common.exception.SeaTunnelRuntimeException","httpStatus":null,"severity":"error","filePath":"seatunnel-connectors-v2/connector-jdbc/src/main/java/org/apache/seatunnel/connectors/seatunnel/jdbc/internal/dialect/gbase8a/Gbase8aTypeMapper.java","lineNumber":105,"sourceCode":"                return BasicType.FLOAT_TYPE;\n            case GBASE8A_CHAR:\n            case GBASE8A_VARCHAR:\n                return BasicType.STRING_TYPE;\n            case GBASE8A_DATE:\n                return LocalTimeType.LOCAL_DATE_TYPE;\n            case GBASE8A_TIME:\n                return LocalTimeType.LOCAL_TIME_TYPE;\n            case GBASE8A_TIMESTAMP:\n            case GBASE8A_DATETIME:\n                return LocalTimeType.LOCAL_DATE_TIME_TYPE;\n            case GBASE8A_BLOB:\n            case GBASE8A_TEXT:\n                return PrimitiveByteArrayType.INSTANCE;\n                // Doesn't support yet\n            case GBASE8A_UNKNOWN:\n            default:\n                final String jdbcColumnName = metadata.getColumnName(colIndex);\n                throw CommonError.convertToSeaTunnelTypeError(\n                        DatabaseIdentifier.GBASE_8A, gbase8aType, jdbcColumnName);\n        }\n    }\n}\n","sourceCodeStart":87,"sourceCodeEnd":110,"githubUrl":"https://github.com/apache/seatunnel/blob/cf67b549a7a6c35fa0beb12d83c62892427ea919/seatunnel-connectors-v2/connector-jdbc/src/main/java/org/apache/seatunnel/connectors/seatunnel/jdbc/internal/dialect/gbase8a/Gbase8aTypeMapper.java#L87-L110","documentation":"This error is thrown by Gbase8aTypeMapper.mapping() when converting a GBase 8a column's JDBC type to a SeaTunnel data type during source schema resolution. The mapper maps recognized GBase 8a types (numeric types, CHAR/VARCHAR, DATE/TIME/TIMESTAMP, TEXT -> PrimitiveByteArrayType, etc.); any type resolving to GBASE8A_UNKNOWN or otherwise unmatched hits the default branch and throws with the GBASE_8A identifier, the GBase type string, and the column name read from the JDBC metadata.","triggerScenarios":"Reading from GBase 8a via the JDBC source when the table contains a column whose JDBC/DB type is not recognized by Gbase8aTypeMapper — e.g. BLOB/LARGE-object variants not covered, DECIMAL/NUMERIC beyond handled precision mapping, spatial types, or unusual vendor-specific type codes reported by the driver.","commonSituations":"Syncing legacy GBase 8a tables that include spatial (GEOMETRY), XML, or rarely-used vendor types. Also occurs when a different/older GBase JDBC driver reports unexpected type names, or after adding new columns with types the connector never handled.","solutions":["Exclude or cast the offending column (from '<field>' in the message) in your source query: SELECT CAST(col AS VARCHAR) AS col ... so it maps to a supported type.","Restrict the read to supported columns via the connector's column_list/query configuration.","Upgrade SeaTunnel — the GBase 8a dialect may have gained mappings for the type.","Extend Gbase8aTypeMapper.mapping() with a case for the unknown type, mapping it to a suitable SeaTunnel type (e.g. STRING or BYTES), and submit upstream."],"exampleFix":"// before: GBase table has GEOMETRY column -> GBASE8A_UNKNOWN\nsource {\n  Jdbc {\n    url = \"jdbc:gbase://host:5258/db\"\n    table_path = \"db.table\"\n  }\n}\n// after: cast unsupported column in query\nsource {\n  Jdbc {\n    url = \"jdbc:gbase://host:5258/db\"\n    query = \"SELECT id, name, ST_AsText(geom) AS geom FROM db.table\"\n  }\n}","handlingStrategy":"validation","validationCode":"-- Pre-flight: list column types for the GBase 8a table and confirm each maps to a scalar type\nSELECT column_name, data_type FROM information_schema.columns WHERE table_name = 'MY_TABLE';\n-- Fail the pipeline early for spatial/LOB/unknown types not in: BIT,TINYINT,SMALLINT,INT,BIGINT,\n-- DECIMAL,FLOAT,DOUBLE,CHAR,VARCHAR,DATE,TIME,TIMESTAMP,TEXT","typeGuard":"// Java: check the JDBC-reported type before asking the mapper to convert\nstatic boolean isSupportedGbase8aType(int jdbcType) {\n    switch (jdbcType) {\n        case Types.BIT: case Types.TINYINT: case Types.SMALLINT: case Types.INTEGER:\n        case Types.BIGINT: case Types.DECIMAL: case Types.NUMERIC: case Types.FLOAT:\n        case Types.DOUBLE: case Types.REAL: case Types.CHAR: case Types.VARCHAR:\n        case Types.DATE: case Types.TIME: case Types.TIMESTAMP: case Types.LONGVARCHAR:\n            return true;\n        default:\n            return false;\n    }\n}","tryCatchPattern":"try {\n    sourceReader.open(...);\n} catch (SeaTunnelRuntimeException e) {\n    if (e.getMessage().contains(\"COMMON-17\") && e.getMessage().contains(\"GBase8a\")) {\n        // extract column name from message and rebuild query with CAST for that column\n        throw new IllegalArgumentException(\"Cast or exclude the reported GBase 8a column\", e);\n    }\n    throw e;\n}","preventionTips":["Inspect table DDL before syncing; GBase 8a GEOMETRY/XML/enum-like columns are not mappable.","Cast problem columns in the source query (e.g. ST_AsText, CAST(... AS VARCHAR)).","Pin and test the GBase JDBC driver version — type codes vary between drivers.","Run a small sample sync to validate schema resolution before full runs."],"tags":["jdbc","gbase8a","type-conversion","unsupported-type"],"backgroundTag":"unsupported-dtype","analyzedSha":"cf67b549a7a6c35fa0beb12d83c62892427ea919","analyzedAt":"2026-09-10T21:44:55.265Z","contentChangedAt":"2026-09-10T21:44:55.265Z","schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}