dbt-labs/dbt-core · error

Oracle

Error message

Oracle

What it means

A `todo!()` panic in `ColumnBuilder::build` (column_builder.rs:40) for the Oracle adapter. No column-building strategy exists for Oracle, so building Column metadata from a schema with an Oracle adapter panics with the message 'Oracle'.

Source

Thrown at crates/dbt-adapter/src/column/column_builder.rs:40

    pub fn build(&self, field: &FieldRef, type_ops: &dyn TypeOps) -> AdapterResult<Column> {
        use AdapterType::*;
        match self.adapter_type {
            Snowflake => Ok(Self::build_snowflake(field, type_ops)),
            Bigquery => Ok(Self::build_bigquery(field, type_ops)),
            Databricks | Spark => Ok(Self::build_databricks(field, type_ops)),
            Redshift => Ok(Self::build_redshift(field, type_ops)),
            Postgres | Salesforce | DuckDB | LakeCompute => {
                Ok(Self::build_postgres_like(field, type_ops))
            }
            Fabric => Ok(Self::build_fabric(field, type_ops)),
            ClickHouse => Self::build_clickhouse(field, type_ops),
            Exasol => Ok(Self::build_exasol(field, type_ops)),
            Starburst => todo!("Starburst"),
            Athena => todo!("Athena"),
            Trino => todo!("Trino"),
            Dremio => todo!("Dremio"),
            Oracle => todo!("Oracle"),
            Datafusion => todo!("Datafusion"),
        }
    }

    pub fn build_from_parts(
        &self,
        name: String,
        dtype: String,
        char_size: Option<u32>,
        numeric_precision: Option<u64>,
        numeric_scale: Option<u64>,
        mode: Option<BigqueryColumnMode>,
    ) -> Column {
        use AdapterType::*;
        match self.adapter_type {
            Postgres => Column::new(
                Postgres,
                name,

View on GitHub (pinned to 0267ce9170)

Solutions

  1. Use a supported adapter for column metadata workflows until Oracle support is added.
  2. Implement the Oracle arm in column_builder.rs:40, mapping NUMBER/VARCHAR2 etc. into the Column model (possibly a dedicated build_oracle).
  3. Replace `todo!()` with a typed error such as DbtError::UnsupportedAdapter for catchable failures.

Example fix

// before
Oracle => todo!("Oracle"),
// after
Oracle => Ok(Self::build_postgres_like(field, type_ops)),
Defensive patterns

Strategy: type-guard

Validate before calling

if adapter == AdapterType::Oracle {
    return Err(anyhow!("Oracle column building is not implemented yet"));
}

Type guard

fn build_supported(t: AdapterType) -> bool {
    matches!(t, Postgres | Salesforce | DuckDB | LakeCompute | Fabric | ClickHouse | Exasol)
}

Try / catch

match std::panic::catch_unwind(AssertUnwindSafe(|| builder.build(field, type_ops))) {
    Ok(r) => r?,
    Err(_) => return Err(anyhow!("column building not implemented for Oracle")),
}

Prevention

When it happens

Trigger: schema_to_columns, get_column_schema_from_query, or update_node_columns invoked with adapter type Oracle — typically during query-result schema extraction or docs/catalog generation.

Common situations: Running schema introspection against an Oracle adapter profile before the Oracle arm was implemented; also reached when tests sweep all AdapterType variants through `build`.

Related errors


AI-assisted analysis of dbt-labs/dbt-core@0267ce9170 (2026-09-07). Data as JSON: /api/errors/d68bf2b158b1ba42. Report an issue: GitHub.