On this Page
Table of Contents | ||||
---|---|---|---|---|
|
Snap type: | Transform | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Description: | This Snap allows you to fetch data from a Cassandra database by providing a table name and configuring the connection. The Snap produces the records from the database on its output view which can then be processed by a downstream Snap. Limit and offset are not supported by Cassandra JDBC driver. Queries produced by the Snap have an equivalent format:
| ||||||||||||
Prerequisites: | Validated Cassandra account, verified network connectivity to Cassandra server and port, and the Cassandra server running. | ||||||||||||
Support and limitations: |
| ||||||||||||
Known Issues: | The Cassandra Select Snap supports inet Data Type that stores the IP address values. Upon validation, the Snap must display a blank space followed by the corresponding IP address value in its output view, which is the expected behavior. But, in the 4.24 Release, this Snap incorrectly displays empty string as null for inet Data Type followed by the IP address value in its output view. | ||||||||||||
Account: | This Snap uses account references created on the Accounts page of SnapLogic Manager to handle access to this endpoint. See Configuring Cassandra Accounts for information on setting up this type of account. | ||||||||||||
Views: |
| ||||||||||||
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 | The database schema name. In case it is not defined, then the suggestion for the table name will retrieve all tables names of all schemas. The property is suggestible and will retrieve available database schemas during suggest values. Example: SYS Default value: [None] | ||||||||||||
Table Name | Required. The name of table to execute select query on. Default value: [None] | ||||||||||||
Where clause | WHERE clause of SELECT statement. The value to be used in the WHERE clause will be used here. Document value substitutions (such as $person.firstname with the value found in the incoming document at the path) can also be used as needed. The "=" will not need to be checked when using document value substitutions unless using expression language. Examples:
Default value: [None]
| ||||||||||||
Order by: Column names | Enter in the columns in the order in which you want to order by. The default database sort order will be used. Example: name Default value: [None] | ||||||||||||
Output fields | Enter or select output field names for SQL SELECT statement. To select all fields, leave it at default. Example: email, address, first, last, etc. Default value: [None] | ||||||||||||
Fetch Output Fields In Schema |
Default value: Not selected | ||||||||||||
Pass through | If checked, the input document will be passed through to the output view under the key 'original'. Default value: Selected | ||||||||||||
Number of retries | Specifies 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. Example: 3 Default value: 0
| ||||||||||||
Retry interval (seconds) | Specifies the time interval between two successive retry requests. A retry happens only when the previous attempt resulted in an exception. Example: 10 Default value: 1 | ||||||||||||
Staging mode | Required when the value in the Number of retries field is greater than 0. Specify the location from the following options to store input documents between retries:
| ||||||||||||
|
|
Note |
---|
For the 'Suggest' in the Order by columns and the Output fields properties, the value of the Table name property should be an actual table name instead of an expression. If it is an expression, it will display an error message "Could not evaluate accessor: ..." when the 'Suggest' button is clicked. This is because, at the time the "Suggest" button is clicked, the input document is not available for the Snap to evaluate the expression in the Table name property. The input document is available to the Snap only during the preview or execution time. |
Troubleshooting
- Run Cassandra JDBC driver using another JDBC tool to verify syntax and results.
Examples
Passing values in Where clause property with Expressions:
Passing values in Where clause property without Expressions:
Insert excerpt | ||||||
---|---|---|---|---|---|---|
|