Trying to use `prefect-dbt` to interact with Redsh...
# ask-community
m
Trying to use
prefect-dbt
to interact with Redshift.
Copy code
target_configs = PostgresTargetConfigs.load(<name>, validate=False)
    dbt_cli_profile = DbtCliProfile(
        name=name,
        target=target,
        target_configs=target_configs.dict(),
    )
    result = trigger_dbt_cli_command(
        "dbt docs generate",
        dbt_cli_profile=dbt_cli_profile,
        overwrite_profiles=True,
        return_state=True,
        project_dir=project_dir,
    )
which gave me
Copy code
Database Error
  relation "pg_matviews" does not exist
s
It looks like the object doesn't exist in redshift. Have you successfully run this outside of
prefect-dbt
with dbt Core?
m
Yep! The issue was that I though the PG stuff was the way to interact with Redshift (cuz that's how it works in regular dbt).