Skip to content

Commit 2deea41

Browse files
committed
filter by latest job runs
1 parent 6cc8bed commit 2deea41

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

src/databricks/labs/ucx/queries/assessment/main/01_4_table_crawl_failures.sql

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,7 @@ WITH latest_job_runs AS (
3131
USING (job_id, job_run_id)
3232
WHERE
3333
workflow_name IN ('assessment')
34-
),
35-
WITH table_crawl_failures AS (
34+
), table_crawl_failures AS (
3635
SELECT
3736
timestamp,
3837
REGEXP_EXTRACT(message, '^failed-table-crawl: (.+?) -> (.+?): (.+)$', 1) AS error_reason,
@@ -42,14 +41,12 @@ SELECT
4241
job_id,
4342
workflow_name,
4443
task_name
45-
FROM latest_job_runs
44+
FROM logs_latest_job_runs
4645
WHERE
4746
STARTSWITH(message, 'failed-table-crawl: ')
4847
)
4948
SELECT
5049
timestamp,
51-
workspace_group,
52-
account_group,
5350
error_message,
5451
job_run_id,
5552
job_id,

0 commit comments

Comments
 (0)