abortWarehouseQueries

Aborts all running and queued queries on a Snowflake warehouse. This is an operational command useful during deployments or maintenance windows when you need to terminate warehouse activity.

Note: This change type does not support automatic rollback or database inspection features (snapshot, diff, diff-changelog, and generate-changelog commands).

Available attributes

Attribute

Type

Description

Required

warehouseName

String

Name of the warehouse to abort queries on

Yes

ifExists

Boolean

If true, only aborts queries if the warehouse exists

No

<?xml version="1.0" encoding="UTF-8"?>
<databaseChangeLog
  xmlns="http://www.liquibase.org/xml/ns/dbchangelog"
  xmlns:pro-snowflake="http://www.liquibase.org/xml/ns/pro-snowflake"
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog
        http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-latest.xsd
        http://www.liquibase.org/xml/ns/pro-snowflake
        http://www.liquibase.org/xml/ns/pro-snowflake/liquibase-pro-snowflake-latest.xsd">
  <!-- Abort all queries on warehouse -->
  <changeSet id="abort-queries" author="examples">
    <pro-snowflake:abortWarehouseQueries warehouseName="ANALYTICS_WH"/>
  </changeSet>
  <!-- Abort with IF EXISTS -->
  <changeSet id="abort-queries-if-exists" author="examples">
    <pro-snowflake:abortWarehouseQueries
            warehouseName="ANALYTICS_WH"
            ifExists="true"/>
  </changeSet>
</databaseChangeLog>