Description

Used to return the job history of all ongoing and historical refreshes. Currently, only the most recent 10,000 records from the past 7 days will be displayed. The results can show how many incremental refreshes there are, whether it is an incremental refresh, etc.

Syntax

 SHOW DYNAMIC TABLE REFRESH HISTORY [where <expr>] [LIMIT num];

Parameter Description

  • WHERE <expr>: (Optional) Allows users to filter based on the fields displayed by the SHOW JOBS command. Users can use expressions to filter the results for more precise data retrieval.
  • LIMIT num: (Optional) Limits the number of job records returned, ranging from 1-10000.

Return Results

FieldDescription
workspace_nameWorkspace name
schema_nameSchema name
nameDynamic table name
virtual_clusterComputing cluster used
start_timeRefresh start time, timestamp type
end_timeRefresh end time, timestamp type
durationRefresh duration, interval type
stateJob status
refresh_triggerMANUAL (manually triggered by user, including studio scheduling) SYSTEM_SCHEDULED (scheduled by lakehouse)
suspended_resonReserved field with no special meaning
refresh_modeNO_DATA FULL INCREMENTAL
error_messageInformation on refresh failure
source_tablesRecords the base table names used by the dynamic table
statsInformation on incremental refresh counts
completion_targetReserved field with no special meaning
job_idJob ID, clicking on the job ID allows viewing of the job profile

Example

  • Filter the corresponding refresh history based on the dynamic table name
 SHOW DYNAMIC TABLE REFRESH HISTORY  where name='dau';
  • Filter based on time consumption, filtering out UI elements that take more than one second
 SHOW DYNAMIC TABLE REFRESH HISTORY  where name='dau' and duration>interval 1 second;
  • Filter based on computing cluster
 SHOW DYNAMIC TABLE REFRESH HISTORY  where name='dau' and duration>interval 1 second and virtual_cluster='DEFAULT';
  • Filter by start time
 SHOW DYNAMIC TABLE REFRESH HISTORY  where name='dau' and duration>interval 1 second and virtual_cluster='DEFAULT'  and start_time>timestamp'2024-06-12 12:47:07.881';