Hi there! Is there a way to get Elementary to not ...
# community-support
l
Hi there! Is there a way to get Elementary to not run on PR jobs? These run in a separate environment from prod. I've set my variables to the following:
Copy code
disable_tests_results: "{{ target.name != 'prod' }}"
  disable_run_results: "{{ target.name != 'prod' }}"
  disable_dbt_artifacts_autoupload: "{{ target.name != 'prod' }}"
  disable_dbt_invocation_autoupload: "{{ target.name != 'prod' }}"
But Elementary continues to run the data monitors on the PR job even though I've excluded them. It is failing the job due to this error
Copy code
Database Error in test elementary_column_anomalies
  Table "None" must be qualified with a dataset (e.g. dataset.table).
Any ideas how I can resolve this?
j
have you tried this in
dbt_project
?
Copy code
models:
  ...
  elementary:
    +schema: elementary
    enabled: "{{ target.name == 'prod' }}"
🙌 1
drop corrupt happy 1
another thing to check is the target name for the pull request job. not sure if you're using dbt cloud?
l
Checked and verified it is not pointing to
prod
j
I'm guessing the variable is defined in the
dbt_project
file?
I don't think you can reference variables defined in it within the file itself
I think you could leverage environment variables instead?
you can define it by environment: the columns are key, project default, development, production
l
Thanks Jenny! Figured it out - looks like disabling edr_cli_run does the trick. Appreciate the help!
🙌 2
drop corrupt happy 1