Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

On this Page

Table of ContentsmaxLevel2exclude


Older Versions|Additional Resources|Related Links|Related Information

Snap type:

Write


Description:

This Snap executes a SQL DELETE with the given properties.
 

Prerequisites:
[None]

N/A

Support and limitations:
Ultra pipelines: 

Works in Ultra Task Pipelines.

  • Spark mode: Not supported in Spark mode.
  • Account: 

    This Snap uses account references created on the Accounts page of SnapLogic Manager to handle access to this endpoint.

     See Vertica Account for

     See Configuring Vertica Accounts for information on setting up this type of account.

    Views:


    InputThis Snap has exactly one input view.
    OutputThis Snap has at most one output view.
    Error

    This Snap has at most one error view and produces zero or more documents in the view.

    Note
    Database Write Snaps output all records of a batch (as configured in your account settings) to the error view if the write fails during batch processing.



    Settings

    Label


    Required. The name for the Snap. You can modify this to be more specific, especially if you have more than one of the same Snap in your pipeline.

    Schema name 


    Required. The database schema name. Selecting a schema filters the Table name list to show only those tables within the selected schema. The property is suggestible and retrieves available database schemas during suggest values.

    Note

    The values can be passed using the pipeline parameters but not the upstream parameter.

    Examplepublic

    Default value: [None]

    Table name


    Required. The table on which to execute the insert operation.

    Note

    The values can be passed using the pipeline parameters but not the upstream parameter.

    Exampleemp

    Default value: [None]Exampleemail = "customer@example.com"
    Default value: 
    [None]

    Delete condition (deletes all records from table if left blank)


    This is an expression property to specify the SQL WHERE clause of the delete statement. The delete condition may also be passed via an upstream Snap or through the pipeline parameters.


    The WHERE clause of delete statement. Document field values can be substituted into the WHERE clause by providing the path. For example, $emp.empno would insert the field 
    empno from the emp object into the query (empno == $emp.empno would become empno == 101 if $emp.empno evaluates to 101).

    Note
    This field is optional, however, the operation deletes a whole table if a proper WHERE clause is not entered.

    Specify a valid WHERE clause for the delete condition. If you leave this field blank, the Snap deletes all the records from the table.

    Examples

    Without using expressions

    Using expressions

    • "EMPNO=$EMPNO and ENAME=$EMPNAME"

    • email = $email 

    • emp=$emp

    • "emp='" + $emp + "'"

    • "EMPNO=" + $EMPNO + " and ENAME='" + $EMPNAME+ "'"


    Warning
    titleCaution

    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. 


    Without using expressions

    Using expressions

    • "EMPNO=$EMPNO and ENAME=$EMPNAME"

    • email = $email 

    • emp=$emp

    • "emp='" + $emp + "'"

    • "EMPNO=" + $EMPNO + " and ENAME='" + $EMPNAME+ "'"


    Number of retries

    The maximum number of times that the process must be retried before displaying an error.

    Default value: 0
    Example: 2

    Retry interval (seconds)

    The maximum resting time in seconds between subsequent retries.

    Default value: 1
    Example: 2

    Multiexcerpt include macro
    nameSnap Execution
    pageSOAP Execute

    Multiexcerpt include macro
    nameExecution_Detail_Write
    pageSOAP Execute


    Insert excerpt
    Vertica Snap Pack
    Vertica Snap Pack
    nopaneltrue