Snowflake - Delete
Overview
You can use this Snap to execute a Snowflake SQL delete with the given properties.

Write-type Snap
-
Works in Ultra Tasks
Prerequisites
You must have minimum permissions on the database to execute Snowflake Snaps. To understand if you already have them, you must retrieve the current set of permissions. The following commands enable you to retrieve those permissions:
SHOW GRANTS ON DATABASE <database_name>
SHOW GRANTS ON SCHEMA <schema_name>
SHOW GRANTS TO USER <user_name>
- Usage (DB and Schema): Privilege to use the database, role, and schema.
grant usage on database <database_name> to role <role_name>;
grant usage on schema <database_name>.<schema_name>;
Learn more about Snowflake privileges: Access Control Privileges.
This Snap uses the DELETE command internally. It enables deleting data from a table using an optional WHERE clause and/or additional tables.
Known Issues
Because of performance issues, all Snowflake Snaps now ignore the Cancel queued queries when pipeline is stopped or if it fails option for Manage Queued Queries, even when selected. Snaps behave as though the default Continue to execute queued queries when the Pipeline is stopped or if it fails option were selected.
Snap views
View | Description | Examples of upstream and downstream Snaps |
---|---|---|
Input | The table name and the relevant delete condition for the table to be deleted. | |
Output | The output document displays:
|
|
Error |
Error handling is a generic way to handle errors without losing data or failing the Snap execution. You can handle the errors that the Snap might encounter when running the pipeline by choosing one of the following options from the When errors occur list under the Views tab. The available options are:
Learn more about Error handling in Pipelines. |
Snap settings
- Expression icon (
): Allows using JavaScript syntax to access SnapLogic Expressions to set field values dynamically (if enabled). If disabled, you can provide a static value. Learn more.
- SnapGPT (
): Generates SnapLogic Expressions based on natural language using SnapGPT. Learn more.
- Suggestion icon (
): Populates a list of values dynamically based on your Snap configuration. You can select only one attribute at a time using the icon. Type into the field if it supports a comma-separated list of values.
- Upload
: Uploads files. Learn more.
Field / Field set | Type | Description |
---|---|---|
Label | String | Required. Specify a unique name for the Snap. Modify this to be more appropriate, especially if there are more than one of the same Snap in the pipeline. |
Schema name | String/Expression | Required. Specify the database schema name. In case it
is not defined, then the suggestion for the Table Name retrieves all tables names of
all schemas. The property is suggestible and will retrieve available database
schemas during suggest values. Note: The values can be passed using the pipeline
parameters but not the upstream parameter.
Default value: N/A Example: Schema_demo |
Table Name | String/Suggestion | Required. Specify the name of the table to execute
delete operation. Note:
Default value: N/A Example: employees_table |
Delete condition (deletes all records from table if left blank) | String/Suggestion | Specify the Snowflake SQL WHERE clause of the delete statement. The delete
condition may also be passed via an upstream Snap or through the pipeline
parameters. Note: Specify a valid WHERE clause for the delete condition. If you
leave this field blank, the Snap deletes all the records from the table.
Without using expressions
Note: Using expressions that join strings together to create SQL queries or
conditions has a potential SQL injection risk and is hence unsafe. Ensure that you
understand all implications and risks involved before using concatenation of
strings with '=' Expression enabled.
|
Number of retries | Integer | Specify the maximum number of attempts to be made to receive a response. The
request is terminated if the attempts do not result in a response.
Minimum Value: 0 Note: Ensure that the local drive has sufficient free
disk space to store the temporary local file. Default value: 0 Example: 3 |
Retry interval (seconds) | Integer | Specify the time interval between two successive retry requests. A retry
happens only when the previous attempt resulted in an exception. Default value: 1 Example: 10 |
Manage Queued Queries | Dropdown list |
Default value: Select this property to decide whether the Snap should continue or cancel the execution of the queued Snowflake Execute SQL queries when you stop the pipeline. Note: If you select Cancel queued queries when the pipeline is stopped or if it
fails, then the read queries under execution are canceled, whereas the write
type of queries under execution are not canceled. Snowflake internally
determines which queries are safe to be canceled and cancels those
queries.
Default value: Continue to execute queued queries when the Pipeline is stopped or if it fails Example: Cancel queued queries when the pipeline is stopped or if it fails |
Snap execution | Dropdown list | Choose one of the three modes in which the Snap executes. Available options
are:
|