diff --git a/elementary/monitor/dbt_project/macros/base_queries/current_tests_run_results_query.sql b/elementary/monitor/dbt_project/macros/base_queries/current_tests_run_results_query.sql index 894a53da1..1d15c6a58 100644 --- a/elementary/monitor/dbt_project/macros/base_queries/current_tests_run_results_query.sql +++ b/elementary/monitor/dbt_project/macros/base_queries/current_tests_run_results_query.sql @@ -49,7 +49,7 @@ when elementary_test_results.test_type = 'schema_change' then elementary_test_results.test_unique_id {# In old versions of elementary, elementary_test_results doesn't contain test_short_name, so we use dbt_test short_name. #} when dbt_tests.short_name = 'dimension_anomalies' then elementary_test_results.test_unique_id - else coalesce(elementary_test_results.test_unique_id, 'None') || '.' || coalesce(elementary_test_results.column_name, 'None') || '.' || coalesce(elementary_test_results.test_sub_type, 'None') + else coalesce(elementary_test_results.test_unique_id, 'None') || '.' || coalesce(nullif(elementary_test_results.column_name, ''), 'None') || '.' || coalesce(elementary_test_results.test_sub_type, 'None') end as elementary_unique_id, elementary_test_results.invocation_id, elementary_test_results.data_issue_id,