Delete Tables
    • Dark
      Light

    Delete Tables

    • Dark
      Light

    Article Summary

    Delete Tables Component

    This component allows you to delete a list of tables in a single operation.

    Note that the Delete Component has more in common with the Snowflake DROP TABLE statement than the DELETE statement. For detailed information on DROP TABLE in Snowflake, refer to the official documentation.

    This component may be used inside a transaction. However, on rollback, deleted tables will NOT be restored.

    Note that the Delete Component has more in common with the Redshift DROP TABLE statement than the DELETE statement. For detailed information on DROP TABLE in Redshift, refer to the official documentation. When deleting large amounts of table data, it is recommended you use a Vacuum Component afterward in order to save space on the cluster.

    This component may be used inside a transaction. On commit, the table is removed permanently. On rollback, it will be retained.

    For detailed information on deleting tables in BigQuery, refer to the official documentation.

    Important Information for Delta Lake Users

    Dropping tables from a data lake has the potential to destroy data.

    Dropping a managed table will remove the associated data that has been stored in the table.

    Dropping an unmanaged table simply removes the association between the table and the underlying data file—the file remains in place on the storage medium.

    Properties

    Snowflake Properties

    PropertySettingDescription
    NameTextA human-readable name for the component.
    WarehouseSelectChoose a Snowflake warehouse that will delete the table.
    DatabaseSelectSelect the database that the deleted table belongs to.
    SchemaSelectSelect the table schema. The special value, [Environment Default] will use the schema defined in the environment. For more information on using multiple schemas, see this article.
    Tables to DeleteSelectOne or more tables to delete.
    Ignore MissingSelectYes - If the table doesn't exist, ignore it.
    No - If a table doesn't exist, generate an error.

    Redshift Properties

    PropertySettingDescription
    NameTextA human-readable name for the component.
    SchemaSelectSelect the table schema. The special value, [Environment Default] will use the schema defined in the environment. For more information on using multiple schemas, see this article.
    Tables to DeleteSelectOne or more tables to delete.
    CascadeSelectYes - Drop dependent objects such as any dependent views that have been manually created.
    No - Do not drop them. The component will fail at runtime if such objects exist and the table will not be removed.
    Ignore MissingSelectYes - If the table doesn't exist, ignore it.
    No - If a table doesn't exist, generate an error.

    BigQuery Properties

    PropertySettingDescription
    NameTextA human-readable name for the component.
    DatasetSelectSelect the table dataset. The special value, [Environment Default] will use the dataset defined in the environment.
    For more information on Google Cloud Datasets, visit the official documentation.
    Tables to DeleteSelectOne or more tables to delete.
    Ignore MissingSelectYes - If the table doesn't exist, ignore it.
    No - If a table doesn't exist, generate an error.

    Synapse Properties

    PropertySettingDescription
    NameTextA human-readable name for the component.
    SchemaSelectSelect the table schema. The special value, [Environment Default], will use the schema defined in the environment.
    For more information on schemas, please see the Azure Synapse documentation.
    TablesSelectSelect the one or more tables to delete.
    Ignore MissingSelectYes - If the table doesn't exist, ignore it.
    No - If a table doesn't exist, generate an error.

    Delta Lake Properties

    PropertySettingDescription
    NameTextA human-readable name for the component.
    CatalogSelectSelect a Databricks Unity Catalog. The special value, [Environment Default], will use the catalog specified in the Matillion ETL environment setup. Selecting a catalog will determine which databases are available in the next parameter.
    DatabaseSelectSelect the Delta Lake database. The special value, [Environment Default], will use the database specified in the Matillion ETL environment setup.
    TablesTable SelectSelect any tables to delete.
    Ignore MissingSelectYes: if the table cannot be found, ignore it and continue running.
    No: if a table cannot be found, generate an error.
    Fail on Managed DeleteSelectYes: the component will fail if the table being deleted is a managed table.

    Strategy

    Generates a single DROP TABLE statement, optionally with IF EXISTS and CASCADE modifiers.
    Generates a single DELETE command.

    What's Next