- Categories:
DCM_DEPLOYMENT_HISTORY¶
This table function returns the deployment history for DCM project objects. You can use it to query successful and failed deployments, including timestamps, status, error details, and summary statistics. The function provides role-based access and low-latency results.
Syntax¶
Arguments¶
All arguments are optional.
PROJECT_NAME => 'string'Fully qualified name of the DCM project. If not provided, the function returns history for all projects accessible by the current role.
START_TIME_RANGE_START => constant_exprTimestamp (in TIMESTAMP_LTZ format) marking the start of the time range for retrieving deployment events.
Default: 7 days ago.
START_TIME_RANGE_END => constant_exprTimestamp (in TIMESTAMP_LTZ format) marking the end of the time range for retrieving deployment events.
Default: current timestamp.
RESULT_LIMIT => integerMaximum number of rows to return.
Default:
10000.
Output¶
The function returns the following columns:
Column name |
Data type |
Description |
|---|---|---|
|
VARCHAR |
Unique identifier of the query that executed the deployment. |
|
VARCHAR |
Name of the DCM project that was deployed. |
|
TIMESTAMP_LTZ |
Timestamp of when the deployment execution started. |
|
TIMESTAMP_LTZ |
Timestamp of when the deployment execution completed or failed. |
|
VARCHAR |
Internal deployment identifier (for example, |
|
VARCHAR |
User-specified alias for the deployment. Empty if no alias was provided. |
|
VARCHAR |
Result of the deployment. Possible values: |
|
VARCHAR |
The phase of the execution. Possible values: |
|
VARCHAR |
Name of the configuration profile used for the deployment. Empty if no configuration was specified. |
|
VARCHAR |
Error message if the deployment failed. Empty for successful deployments. |
|
VARCHAR |
Error code if the deployment failed. Empty for successful deployments. |
|
VARCHAR |
Database that contains the DCM project. |
|
VARCHAR |
Schema that contains the DCM project. |
|
VARCHAR |
Role that executed the deployment command. |
|
VARIANT |
JSON object containing summary statistics of the deployment, broken down by category. Each
category contains counts of |
Usage notes¶
When calling an Information Schema table function, the session must have an INFORMATION_SCHEMA schema in use or the function name must be fully qualified. For more details, see Snowflake Information Schema.
Examples¶
Retrieve deployment history for a specific project, limited to 3 results:
The STATS column contains a JSON object with the following structure:
Retrieve all columns for all projects accessible by the current role within the last 24 hours: