{"record":{"id":"cbe7d702e4cbdf53","repo":"risingwavelabs/risingwave","slug":"unsupported-data-type-set-to-null","errorCode":null,"errorMessage":"unsupported data type: {}, set to null","messagePattern":"unsupported data type: (.+?), set to null","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"src/connector/src/parser/mysql.rs","lineNumber":245,"sourceCode":"                ))),\n        },\n        DataType::Jsonb => {\n            handle_data_type!(\n                mysql_row,\n                mysql_datum_index,\n                column_name,\n                serde_json::Value,\n                JsonbVal\n            )\n        }\n        DataType::Variant\n        | DataType::Vector(_)\n        | DataType::Interval\n        | DataType::Struct(_)\n        | DataType::List(_)\n        | DataType::Int256\n        | DataType::Serial\n        | DataType::Map(_) => Err(anyhow!(\n            \"unsupported data type: {}, set to null\",\n            rw_data_type\n        )),\n    }\n}\n\npub fn mysql_row_to_owned_row(mysql_row: &mut MysqlRow, schema: &Schema) -> OwnedRow {\n    let mut datums = vec![];\n    for i in 0..schema.fields.len() {\n        let rw_field = &schema.fields[i];\n        let name = rw_field.name.as_str();\n        let datum = match mysql_datum_to_rw_datum(mysql_row, i, name, &rw_field.data_type) {\n            Ok(val) => val,\n            Err(e) => {\n                log_error!(name, e, \"parse column failed\");\n                None\n            }\n        };","sourceCodeStart":227,"sourceCodeEnd":263,"githubUrl":"https://github.com/risingwavelabs/risingwave/blob/6469eb736d691e8e9b8a419a57edd6429ca77417/src/connector/src/parser/mysql.rs#L227-L263","documentation":"Raised in `mysql_datum_to_rw_datum` when the RisingWave source column's DataType is one the MySQL datum decoder does not support (Vector, Interval, Struct, List, Int256, Serial, Map). The message notes the value is 'set to null' downstream, but the error itself signals that the declared source schema contains a type not mappable from MySQL CDC data.","triggerScenarios":"Creating a MySQL CDC source/table whose DDL includes an unsupported column type (e.g. STRUCT, LIST, INTERVAL, SERIAL), then ingesting rows so the decoder hits the unsupported arm of the type match.","commonSituations":"Copy-pasting RisingWave DDL with exotic types into a MySQL CDC source; using SERIAL/Int256 columns in an upstream-backed table; schema evolution introducing an unsupported type mid-stream.","solutions":["Remove or change unsupported columns in the source DDL to MySQL-representable types (INT, VARCHAR, etc.).","Replace SERIAL with an explicit BIGINT/AUTO_INCREMENT-mapped column; encode nested data as JSON/VARCHAR instead of STRUCT/LIST.","Recreate the source with a supported schema and let unsupported columns be omitted."],"exampleFix":"// before: unsupported types in MySQL CDC source\ntags STRUCT<a INT, b TEXT>,\n// after: use JSON/varchar representation\ntags JSONB,  -- or VARCHAR storing serialized JSON","handlingStrategy":"validation","validationCode":"-- Before CREATE SOURCE, ensure all column types are MySQL-decodable:\n-- supported: BOOLEAN, INT16/32/64, FLOAT32/64, DECIMAL, VARCHAR, DATE, TIME,\n-- TIMESTAMP, TIMESTAMPTZ, BYTEA. Reject STRUCT/LIST/INTERVAL/SERIAL/Int256/MAP.","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Restrict MySQL CDC source DDL to supported primitive types.","Serialize nested data as JSONB/VARCHAR instead of STRUCT/LIST.","Review type mappings in the RisingWave MySQL CDC docs before designing schemas."],"tags":["mysql","cdc","unsupported-type","schema"],"backgroundTag":"unsupported-dtype","analyzedSha":"6469eb736d691e8e9b8a419a57edd6429ca77417","analyzedAt":"2026-09-11T21:06:21.487Z","contentChangedAt":"2026-09-11T21:06:21.487Z","schemaVersion":2},"datasetVersion":"2026-09-14T16:17:12.679Z"}