{"record":{"id":"a1c1c2ee4977af9b","repo":"dbt-labs/dbt-core","slug":"from-config-only-available-for-snowflake-and-reds","errorCode":null,"errorMessage":"from_config: Only available for Snowflake and Redshift","messagePattern":"from_config: Only available for Snowflake and Redshift","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"crates/dbt-adapter/src/relation/relation_impl.rs","lineNumber":1081,"sourceCode":"                                format!(\"Failed to deserialize InternalDbtNodeWrapper: {e}\"),\n                            )\n                        })?;\n                let local_config = match local_config {\n                    InternalDbtNodeWrapper::Model(model) => model,\n                    _ => {\n                        return Err(minijinja::Error::new(\n                            minijinja::ErrorKind::InvalidOperation,\n                            \"Expected a model node\",\n                        ));\n                    }\n                };\n                let relation_config = SnowflakeConfigRelationType::of(local_config.as_ref())\n                    .loader()\n                    .from_local_config(local_config.as_ref())?;\n\n                Ok(Value::from_object(relation_config))\n            }\n            _ => Err(minijinja::Error::new(\n                minijinja::ErrorKind::InvalidOperation,\n                \"from_config: Only available for Snowflake and Redshift\",\n            )),\n        }\n    }\n\n    fn normalize_component(&self, component: &str) -> String {\n        use AdapterType::*;\n        match self.adapter_type {\n            Salesforce | Bigquery | ClickHouse => component.to_string(),\n            Snowflake => component.to_uppercase(),\n            _ => component.to_lowercase(),\n        }\n    }\n\n    fn render_self_as_str(&self) -> String {\n        if self.adapter_type == AdapterType::DuckDB\n            && let Some(external) = &self.external","sourceCodeStart":1063,"sourceCodeEnd":1099,"githubUrl":"https://github.com/dbt-labs/dbt-core/blob/0267ce9170576975b76b64ce856b2e5848e96617/crates/dbt-adapter/src/relation/relation_impl.rs#L1063-L1099","documentation":"`from_config` is only implemented for the Snowflake adapter despite the message also mentioning Redshift; all remaining AdapterType values hit this wildcard arm. The message text is slightly stale but means: this adapter does not support building a relation from a node config.","triggerScenarios":"Calling BaseRelation.from_config() while running on any adapter other than Snowflake (the Redshift arm does not exist in this match).","commonSituations":"Running a project with relation-from-config macros on Postgres/BigQuery/Databricks, or after switching warehouse profiles.","solutions":["Run the affected models on Snowflake, or use the default relation construction path (from Parliament/parse-time relation) instead of from_config.","Guard macro code with `adapter.type()` checks and fall back to from_parliament/from_dict for other adapters.","Implement a from_config branch for your adapter in relation_impl.rs if needed."],"exampleFix":"// before\nrelation = BaseRelation.from_config(config=config)\n// after\nif adapter.type() == 'snowflake':\n    relation = BaseRelation.from_config(config=config)\nelse:\n    relation = BaseRelation.from_parliament(parliament=parliament)","handlingStrategy":"fallback","validationCode":"{% if adapter.type() == 'snowflake' %}\n  {% set relation = BaseRelation.from_config(config=config) %}\n{% else %}\n  {% set relation = BaseRelation.from_parliament(parliament=parliament) %}\n{% endif %}","typeGuard":"let can_from_config = matches!(adapter_type, AdapterType::Snowflake);","tryCatchPattern":"try:\n    relation = BaseRelation.from_config(config=config)\nexcept minijinja.Error as e:\n    if 'Only available' in str(e):\n        relation = BaseRelation.from_parliament(parliament=parliament)\n    else:\n        raise","preventionTips":["Gate from_config usage on adapter.type() == 'snowflake'","Provide a from_parliament fallback in shared macros","Avoid copying Snowflake-only macros to other adapters unchanged"],"tags":["adapter","unsupported","snowflake","jinja"],"backgroundTag":"unsupported-operation","analyzedSha":"0267ce9170576975b76b64ce856b2e5848e96617","analyzedAt":"2026-09-07T21:53:39.732Z","contentChangedAt":"2026-09-07T21:53:39.732Z","schemaVersion":2},"datasetVersion":"2026-09-14T16:17:12.679Z"}