{"record":{"id":"d5ffe33d8215fa9f","repo":"apache/seatunnel","slug":"can-t-obtain-schema-for-table-s-d5ffe3","errorCode":null,"errorMessage":"Can't obtain schema for table %s ","messagePattern":"Can't obtain schema for table (.+?) ","errorType":"exception","errorClass":"SeaTunnelException","httpStatus":null,"severity":"error","filePath":"seatunnel-connectors-v2/connector-cdc/connector-cdc-oracle/src/main/java/org/apache/seatunnel/connectors/seatunnel/cdc/oracle/utils/OracleSchema.java","lineNumber":94,"sourceCode":"            for (TableId id : tables.tableIds()) {\n                TableId tableMapId = resolveTableId(id, tableId, tableMap);\n                if (tableMap.containsKey(tableMapId)) {\n                    Table table =\n                            CatalogTableUtils.mergeCatalogTableConfig(\n                                    tables.forTable(id), tableMap.get(tableMapId));\n                    TableChanges.TableChange tableChange =\n                            new TableChanges.TableChange(\n                                    TableChanges.TableChangeType.CREATE, table);\n                    schemasByTableId.put(tableMapId, tableChange);\n                }\n            }\n        } catch (SQLException e) {\n            throw new SeaTunnelException(\n                    String.format(\"Failed to read schema for table %s \", tableId), e);\n        }\n\n        if (!schemasByTableId.containsKey(tableId)) {\n            throw new SeaTunnelException(\n                    String.format(\"Can't obtain schema for table %s \", tableId));\n        }\n\n        return schemasByTableId.get(tableId);\n    }\n\n    static TableId resolveTableId(\n            TableId readTableId, TableId requestedTableId, Map<TableId, ?> tableMap) {\n        if (tableMap.containsKey(readTableId)) {\n            return readTableId;\n        }\n\n        TableId readTableIdWithRequestedCatalog =\n                new TableId(requestedTableId.catalog(), readTableId.schema(), readTableId.table());\n        if (tableMap.containsKey(readTableIdWithRequestedCatalog)) {\n            return readTableIdWithRequestedCatalog;\n        }\n","sourceCodeStart":76,"sourceCodeEnd":112,"githubUrl":"https://github.com/apache/seatunnel/blob/cf67b549a7a6c35fa0beb12d83c62892427ea919/seatunnel-connectors-v2/connector-cdc/connector-cdc-oracle/src/main/java/org/apache/seatunnel/connectors/seatunnel/cdc/oracle/utils/OracleSchema.java#L76-L112","documentation":"Thrown by OracleSchema.readTableSchema after the schema read completes but the requested tableId is not present in the built schema map, meaning Debezium produced no TableChange for that table. This indicates the table was not captured by the schema reader at all, rather than a JDBC failure.","triggerScenarios":"readTableSchema finished without error but schemasByTableId has no entry for the requested tableId — typically because the table name in the config doesn't resolve (wrong database/schema prefix, case mismatch) or the table exists but was filtered out.","commonSituations":"Missing or wrong 'database-name'/'schema-name' in tableList (e.g. forgetting the schema prefix); Oracle uppercase vs quoted lowercase identifiers mismatch; typo'd table name; table created after schema capture started.","solutions":["Check the tableList entry includes the full database.schema.table identifier and matches Oracle's actual (usually uppercase) identifiers.","Query ALL_TABLES in Oracle to confirm exact owner/table_name, then fix the config.","Remember unquoted Oracle identifiers are uppercase; quoted lowercase names must be given exactly.","If the table was created after the job started, restart the job so the schema is re-read.","Enable debug logging to inspect which tables Debezium actually captured."],"exampleFix":"// before\ntableList = [\"ORCL.SCOTT.orders\"] // Oracle stores it as SCOTT.ORDERS\n// after\ntableList = [\"ORCL.SCOTT.ORDERS\"]","handlingStrategy":"validation","validationCode":"SELECT owner, table_name FROM all_tables\nWHERE UPPER(owner)=UPPER('SCOTT') AND UPPER(table_name)=UPPER('ORDERS');","typeGuard":null,"tryCatchPattern":"try {\n    TableChange change = oracleSchema.getTableSchema(tableId);\n} catch (SeaTunnelException e) {\n    LOG.warn(\"table {} not captured by schema reader; check tableList casing/prefix\", tableId);\n}","preventionTips":["Match Oracle's uppercase identifiers unless the object was created quoted","Include the schema prefix in every tableList entry","Confirm table existed before job start; late-created tables are not captured","Check metadata-user privileges if PK/schema info seems missing"],"tags":["oracle","cdc","schema-read","table-not-found"],"backgroundTag":"resource-not-found","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"}