{"record":{"id":"8be76677897f5a34","repo":"vitessio/vitess","slug":"unknown-tableid-v-in-deleterows-event","errorCode":null,"errorMessage":"unknown tableID %v in DeleteRows event","messagePattern":"unknown tableID (.+?) in DeleteRows event","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"go/vt/binlog/binlog_streamer.go","lineNumber":581,"sourceCode":"\t\t\t})\n\n\t\t\trows, err := ev.Rows(format, tce.tm)\n\t\t\tif err != nil {\n\t\t\t\treturn pos, err\n\t\t\t}\n\n\t\t\tstatements = bls.appendUpdates(statements, tce, &rows)\n\n\t\t\tif autocommit {\n\t\t\t\tif err = commit(ev.Timestamp()); err != nil {\n\t\t\t\t\treturn pos, err\n\t\t\t\t}\n\t\t\t}\n\t\tcase ev.IsDeleteRows():\n\t\t\ttableID := ev.TableID(format)\n\t\t\ttce, ok := tableMaps[tableID]\n\t\t\tif !ok {\n\t\t\t\treturn pos, fmt.Errorf(\"unknown tableID %v in DeleteRows event\", tableID)\n\t\t\t}\n\t\t\tif tce.ti == nil {\n\t\t\t\t// Skip cross-db statements.\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tsetTimestamp := &binlogdatapb.BinlogTransaction_Statement{\n\t\t\t\tCategory: binlogdatapb.BinlogTransaction_Statement_BL_SET,\n\t\t\t\tSql:      fmt.Appendf(nil, \"SET TIMESTAMP=%d\", ev.Timestamp()),\n\t\t\t}\n\t\t\tstatements = append(statements, FullBinlogStatement{\n\t\t\t\tStatement: setTimestamp,\n\t\t\t})\n\n\t\t\trows, err := ev.Rows(format, tce.tm)\n\t\t\tif err != nil {\n\t\t\t\treturn pos, err\n\t\t\t}\n","sourceCodeStart":563,"sourceCodeEnd":599,"githubUrl":"https://github.com/vitessio/vitess/blob/01a25a7d176f94613b8d59d799f438380a8760e4/go/vt/binlog/binlog_streamer.go#L563-L599","documentation":"Returned by the binlog streamer when a DeleteRows event references a tableID that is not present in the streamer's table map, typically because the corresponding TableMap event was filtered out or skipped.","triggerScenarios":"ev.IsDeleteRows() produces a tableID missing from tableMaps in parseEvents due to a lost/skipped table map event or a corrupt/misaligned binlog stream.","commonSituations":"Stream resumption mid-transaction, binlog truncation/corruption, synthetic binlog generators missing table maps, or aggressive database filtering dropping map events.","solutions":["Restart the stream from a GTID/position at a transaction boundary","Verify the binlog integrity with mysqlbinlog and re-copy if damaged","Keep TABLE_MAP events unfiltered in the stream pipeline","Confirm the binlog producer emits table maps before delete-rows events"],"exampleFix":null,"handlingStrategy":"validation","validationCode":"// confirm pairing before streaming:\n// mysqlbinlog --start-position=<pos> <file> | grep -E 'Table_map|Delete_rows'","typeGuard":null,"tryCatchPattern":"err := streamer.Stream(ctx, signals)\nif err != nil && strings.Contains(err.Error(), \"unknown tableID\") {\n    // restart stream from a clean transaction boundary\n}","preventionTips":["Resume streams at transaction boundaries only","Preserve TABLE_MAP events in any filtering layer","Run mysqlbinlog checks before resuming after crashes","Fix custom binlog emitters to include table maps"],"tags":["binlog","row-replication","table-map"],"backgroundTag":"unknown-table-id-in-binlog","analyzedSha":"01a25a7d176f94613b8d59d799f438380a8760e4","analyzedAt":"2026-09-01T17:28:30.605Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-08T10:18:20.063Z"}