{"record":{"id":"96535cefd3852b4f","repo":"apache/seatunnel","slug":"the-column-with-type-array-will-be-converted-to","errorCode":null,"errorMessage":"The column {} with type ARRAY will be converted to VECTOR in YashanDB","messagePattern":"The column (.+?) with type ARRAY will be converted to VECTOR in YashanDB","errorType":"console","errorClass":null,"httpStatus":null,"severity":"warning","filePath":"seatunnel-connectors-v2/connector-jdbc/src/main/java/org/apache/seatunnel/connectors/seatunnel/jdbc/internal/dialect/yashandb/YashanDbTypeConverter.java","lineNumber":418,"sourceCode":"                            decimalType.getScale(),\n                            MAX_SCALE,\n                            precision,\n                            scale);\n                }\n                builder.columnType(String.format(\"%s(%s,%s)\", NUMBER, precision, scale));\n                builder.dataType(NUMBER);\n                builder.precision(precision);\n                builder.scale(scale);\n                break;\n            case BYTES:\n                builder.columnType(BLOB);\n                builder.dataType(BLOB);\n                break;\n            case ARRAY:\n                // YashanDB does not have a native ARRAY column type, store as vector\n                if (SUPPORT_FLOAT32_VECTOR.contains(\n                        ((ArrayType) column.getDataType()).getElementType().getSqlType())) {\n                    log.warn(\n                            \"The column {} with type ARRAY will be converted to VECTOR in YashanDB\",\n                            column.getName());\n                    builder.columnType(\n                            String.format(\"%s(%s,FLOAT32)\", VECTOR_NAME, column.getColumnLength()));\n                    builder.dataType(VECTOR_NAME);\n                } else if (SUPPORT_FLOAT64_VECTOR.contains(\n                        ((ArrayType) column.getDataType()).getElementType().getSqlType())) {\n                    log.warn(\n                            \"The column {} with type ARRAY will be converted to VECTOR in YashanDB\",\n                            column.getName());\n                    builder.columnType(\n                            String.format(\"%s(%s,FLOAT64)\", VECTOR_NAME, column.getColumnLength()));\n                    builder.dataType(VECTOR_NAME);\n                } else {\n                    throw new UnsupportedOperationException(\n                            \"Unsupport \"\n                                    + ((ArrayType) column.getDataType())\n                                            .getElementType()","sourceCodeStart":400,"sourceCodeEnd":436,"githubUrl":"https://github.com/apache/seatunnel/blob/cf67b549a7a6c35fa0beb12d83c62892427ea919/seatunnel-connectors-v2/connector-jdbc/src/main/java/org/apache/seatunnel/connectors/seatunnel/jdbc/internal/dialect/yashandb/YashanDbTypeConverter.java#L400-L436","documentation":"Warning from YashanDbTypeConverter.reconvert: YashanDB has no native ARRAY type, so ARRAY columns whose element type is in SUPPORT_FLOAT32_VECTOR are converted to a FLOAT32 VECTOR column of the given length. Data shape must be a fixed-length float vector or it will not round-trip as expected.","triggerScenarios":"Catalog sink write/auto table creation in YashanDB for an ARRAY column with FLOAT32-compatible element type (e.g. array<float> / array<int32>), column length taken from getColumnLength().","commonSituations":"Embedding/ML pipelines storing float vectors as arrays in the source (PostgreSQL float4[], SeaTunnel array<float>) synced into YashanDB vector columns.","solutions":["Ensure array element values fit the declared vector length (getColumnLength) before writing.","If a true array is required, serialize to a string/JSON column via a Transform instead of relying on the VECTOR mapping.","Keep element types within FLOAT32-supported ranges to preserve numeric fidelity."],"exampleFix":"// before: source column embedding array<float>\n// after (keep array semantics)\nTransform: MAP(embedding, CAST(x AS STRING)) -> concat to JSON string column","handlingStrategy":"validation","validationCode":"if (col.getDataType() instanceof ArrayType\n        && SUPPORT_FLOAT32_VECTOR.contains(((ArrayType) col.getDataType()).getElementType().getSqlType())) {\n    assert values.size() <= col.getColumnLength(); // vector length check\n}","typeGuard":"boolean mapsToFloat32Vector(ArrayType a) { return SUPPORT_FLOAT32_VECTOR.contains(a.getElementType().getSqlType()); }","tryCatchPattern":null,"preventionTips":["Match array length to declared column length","Serialize arrays via Transform when true array semantics are needed","Test one batch end-to-end before bulk sync into YashanDB vector columns"],"tags":["jdbc","yashandb","type-conversion","vector","array"],"backgroundTag":"type-mismatch","analyzedSha":"cf67b549a7a6c35fa0beb12d83c62892427ea919","analyzedAt":"2026-09-10T21:44:55.265Z","contentChangedAt":"2026-09-10T21:44:55.265Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}