MetricSign
EN|NLRequest Access
Medium severityconfiguration

Power BI Refresh Error:
DbtSnowflakeRoleNotSetError

What does this error mean?

The dbt-snowflake adapter cannot determine which Snowflake role to use because the role field is missing from the dbt profile, causing it to fall back to the user's default role, which may lack the required permissions.

Common causes

  • 1The role field is omitted from the dbt profile and the user's default Snowflake role does not have access to the target schema
  • 2The role field is present but set to None or an empty string
  • 3A model-level snowflake_role config was used for specific models but no base role was set in the profile
  • 4The profile was migrated from another database adapter and the role field was not added

How to fix it

  1. 1Step 1: Add the role field to the Snowflake target in profiles.yml: role: TRANSFORMER.
  2. 2Step 2: Confirm the role exists in Snowflake and is granted to the user: SHOW GRANTS TO USER <username>;
  3. 3Step 3: If using dbt Cloud, update the environment credentials to include the role field.
  4. 4Step 4: Run dbt debug to confirm the active role after the profile change.
  5. 5Step 5: Grant the role the necessary privileges on the target database and schema if it lacks them.

Frequently asked questions

What role should I use for dbt in Snowflake?

Best practice is to create a dedicated TRANSFORMER role with USAGE on the warehouse, database, and schema, plus CREATE TABLE/VIEW in the target schema. Avoid using ACCOUNTADMIN or SYSADMIN for dbt connections.

Can dbt use different roles for different models?

Yes — use the snowflake_warehouse and role model configs to override the profile role for specific models. This is useful for models that write to schemas with different access controls.

Other configuration errors