{"record":{"id":"673640445c023df4","repo":"apache/seatunnel","slug":"unsupported-data-type-673640","errorCode":"UNSUPPORTED_DATA_TYPE","errorMessage":"Unexpected value: ","messagePattern":"Unexpected value: ","errorType":"error_code","errorClass":"JdbcConnectorException","httpStatus":null,"severity":"error","filePath":"seatunnel-connectors-v2/connector-jdbc/src/main/java/org/apache/seatunnel/connectors/seatunnel/jdbc/internal/dialect/inceptor/InceptorJdbcRowConverter.java","lineNumber":146,"sourceCode":"                        Object[] array = (Object[]) row.getField(fieldIndex);\n                        if (array == null) {\n                            statement.setNull(statementIndex, java.sql.Types.ARRAY);\n                            break;\n                        }\n                        if (SqlType.TINYINT.equals(elementType.getSqlType())) {\n                            Short[] shortArray = new Short[array.length];\n                            for (int i = 0; i < array.length; i++) {\n                                shortArray[i] = Short.valueOf(array[i].toString());\n                            }\n                            statement.setObject(statementIndex, shortArray);\n                        } else {\n                            statement.setObject(statementIndex, array);\n                        }\n                        break;\n                    case MAP:\n                    case ROW:\n                    default:\n                        throw new JdbcConnectorException(\n                                CommonErrorCodeDeprecated.UNSUPPORTED_DATA_TYPE,\n                                \"Unexpected value: \" + seaTunnelDataType);\n                }\n            } catch (Exception e) {\n                throw new JdbcConnectorException(\n                        JdbcConnectorErrorCode.DATA_TYPE_CAST_FAILED,\n                        \"error field:\" + rowType.getFieldNames()[fieldIndex],\n                        e);\n            }\n        }\n        return statement;\n    }\n}\n","sourceCodeStart":128,"sourceCodeEnd":160,"githubUrl":"https://github.com/apache/seatunnel/blob/cf67b549a7a6c35fa0beb12d83c62892427ea919/seatunnel-connectors-v2/connector-jdbc/src/main/java/org/apache/seatunnel/connectors/seatunnel/jdbc/internal/dialect/inceptor/InceptorJdbcRowConverter.java#L128-L160","documentation":"Thrown by InceptorJdbcRowConverter.toExternal in the default branch of the array element type switch — the array element's SeaTunnel SQL type has no mapped JDBC writing path, so the row-to-statement conversion aborts with the unmapped value.","triggerScenarios":"Writing rows to Inceptor where a column's SeaTunnel type is MAP, ROW, or falls into the default (unhandled) branch of the type switch in toExternal.","commonSituations":"Source schemas containing nested complex types (maps/structs) being sunk to Inceptor via JDBC; schema evolution introducing types the Inceptor converter doesn't handle.","solutions":["Flatten or cast MAP/ROW columns to supported scalar types upstream (e.g. via a transform) before sinking.","Add support for the needed data types in InceptorJdbcRowConverter.toExternal and contribute upstream.","Change the table schema so complex columns are serialized (e.g. as JSON strings) into supported Inceptor types."],"exampleFix":"// before\nfield m map<string,int>  # passed straight to Inceptor sink\n// after (transform to string)\ntransform { plugin_name = \"FieldMapper\", ... }  # or stringify map to JSON string first","handlingStrategy":"validation","validationCode":"// reject unsupported complex types before sinking\nfor (SeaTunnelDataType<?> t : rowType.getFieldTypes()) {\n  if (t.getSqlType() == SqlType.MAP || t.getSqlType() == SqlType.ROW) throw new IllegalArgumentException(\"Unsupported type for Inceptor sink: \" + t);\n}","typeGuard":"boolean inceptorSupported(SqlType s) { return !(s == SqlType.MAP || s == SqlType.ROW); }","tryCatchPattern":"try { converter.toExternal(schema, schema, row, ps); } catch (JdbcConnectorException e) { if (e.getErrorCode() == CommonErrorCodeDeprecated.UNSUPPORTED_DATA_TYPE) { /* flatten/map the complex column and retry */ } else throw e; }","preventionTips":["Flatten or stringify MAP/ROW columns before the Inceptor sink","Keep sink schemas to scalar types supported by the Inceptor converter","Add schema compatibility checks in pipeline config review"],"tags":["jdbc","inceptor","data-type","converter"],"backgroundTag":"unsupported-dtype","analyzedSha":"cf67b549a7a6c35fa0beb12d83c62892427ea919","analyzedAt":"2026-09-10T21:44:55.265Z","contentChangedAt":"2026-09-10T21:44:55.265Z","schemaVersion":2},"datasetVersion":"2026-09-14T11:17:12.474Z"}