connection to dbt and snowfalke was successful but when tried to run this command:
$ dbt runit gives this error
ERROR: Runtime Error Could not find profile named 'learn_dbt' Encountered an error: Runtime Error Could not run dbt"
Am I making any command mistake?
5 Answers
There are a few different approaches to solving to this problem:
- Check the profile key in your
dbt_project.yml - Check the profiles you have in your
profiles.yml - Run
dbt debug --config-dirto check where dbt thinks your config file is.
See the dbt documentation here
This is a problem in your profiles.yml file. You are running a project that requires you build a "dbt-learn" profile to run.
I think got the solution for this error if we give the dir name i,e dbt run --profiles-dir <path/of/.dbt folder>
For these types of errors you must ensure that your
**profile: 'snowflake' # This setting configures which "profile" dbt uses for this project.**matches the first key in profile.yml see
For me the issue was that i didn't put all string profile parameters value(like host, user, pass...) inside a quotation marks. While there is an example in documentation when they are also omitted. So it was something like this
jaffle_shop: target: dev outputs: dev: type: postgres threads: 1 host: localhost port: 5432 user: postgres pass: example dbname: postgres schema: publicAnd it didn't work, but after i changed it to the following everything worked
jaffle_shop: outputs: dev: type: postgres threads: 1 host: "localhost" port: 5432 user: "postgres" pass: "example" dbname: "postgres" schema: "public"