导入
配置文件(orientation)
了解 dbt 配置文件的工作原理,以及如何测试连接的有效性。
1finance: 2 outputs: 3 dev: 4 dataset: finance 5 job_execution_timeout_seconds: 300 6 job_retries: 1 7 keyfile: credentials.json 8 location: US 9 method: service-account 10 priority: interactive 11 project: shoe-store 12 threads: 1 13 type: bigquery 14 target: dev 15marketing: 16 outputs: 17 dev: 18 dataset: dataset 19 job_execution_timeout_seconds: 300 20 job_retries: 1 21 keyfile: credentials.json 22 location: US 23 method: service-account 24 priority: interactive 25 project: shoe-store 26 threads: 1 27 type: bigquery 28 target: dev
1 2# 为项目命名!项目名称只能包含小写字母和下划线。一个好的包名称应反映您的组织名称或这些模型的预期用途 3name: 'digital_marketing' 4version: '1.0.0' 5config-version: 2 6 7# 此设置配置 dbt 在此项目中使用的“配置文件” 8profile: 'marketing' 9 10# 这些配置指定 dbt 应该在何处查找不同类型的文件。 11# 例如,`model-paths` 配置表示该项目中的模型位于 "models/" 目录中。您可能不需要更改这些设置! 12model-paths: ["models"] 13analysis-paths: ["analyses"] 14test-paths: ["tests"] 15seed-paths: ["seeds"] 16macro-paths: ["macros"] 17snapshot-paths: ["snapshots"] 18 19target-path: "target" # 存放编译后 SQL 文件的目录 20clean-targets: # 通过 `dbt clean` 命令清除的目录 21 - "target" 22 - "dbt_packages" 23 24 25# 模型配置 26# 完整文档:https://docs.getdbt.com/docs/configuring-models 27 28# 在此示例配置中,我们告诉 dbt 将 example/ 目录下的所有模型构建为表。 29# 这些设置可以在单个模型文件中通过 `{{ config(...) }}` 宏进行覆盖。 30models: 31 test_project: 32 # 由 + 标记的配置,适用于 models/example/ 下的所有文件 33 example: 34 +materialized: view
1dbt debug
...
终端截图
...
终端截图
No configuration found for ID: 99ec6bf9c7f9787a01c3c517e735281764971ce770d113092adbc522a9348f7f