Teradata FastExport
Overview
The Teradata FastExport Snap exports data from a Teradata database by providing a table name and configuring the connection.
The Snap writes the exported data to the specified file and provides the console output and status code on the output view for any downstream Snap checking for successful execution.
Queries produced by the Snap have the format:
SELECT <columns> FROM <schema.table> WHERE <where clause> ORDER BY <order clause>
- This is a Read-type Snap.
Works in Ultra Tasks
Snap views
| Type | Description | Examples of upstream and downstream Snaps |
|---|---|---|
| Input |
This Snap has at most one document input view. Anything that is immediately substituted by the Snap itself will work, but anything that is used as a substitution in a query will fail. |
|
| Output |
This Snap has at most one document output view. FASTLOAD, Binary, and Unformat are all binary and support non-textual fields (INT, DATE, etc.). Text is fixed-width text, but explicitly only supports text fields. Expected downstream Snaps: A Snap monitoring the exit code to check result status. Expected output: A single document containing the console output and return status from the external Teradata application. |
|
| Learn more about Error handling. | ||
Snap settings
- Expression icon (
): Allows using pipeline parameters to set field values dynamically (if enabled). SnapLogic Expressions are not supported. If disabled, you can provide a static value.
- 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 | Description | |
|---|---|---|
Label
String |
Required. Specify a unique name for the Snap. Modify this to be more appropriate, especially if more than one of the same Snaps is in the pipeline. Default value: Teradata FastExport |
|
Schema name
String/Expression/ Suggestion |
The database schema name. If not defined, the suggestion for the table name retrieves all table names of all schemas. The property is suggestible and retrieves available database schemas during suggest values.
Default value: N/A Example: SYS |
|
Table name
String/Expression |
Required. Name of the table to execute a select query on.
Default value: N/A Example: people |
|
Where clause
String/Expression |
Where clause of the select statement. This supports document value substitution (such as $person.firstname will be substituted with the value found in the incoming document at the path). However, you may not use a value substitution after IS or is word.
Without using expressions:
Using expressions:
Default value: N/A Example: EmpId = 12 |
|
Order by
String/Expression |
Enter the columns in the order in which you want to order by. The default database sort order will be used.
Default value: N/A Example: name, email |
|
Limit rows
Integer/Expression |
The number of rows the query should return.
Default value: N/A Example: 100 |
|
Output fields
String/Expression |
Enter or select output field names for SQL SELECT statement. To select all fields, leave it at default. Fields available include:
Default value: N/A Example: email, address, first, last |
|
Fetch Output Fields In Schema
Checkbox |
Select this checkbox to include only the selected fields or columns in the Output Schema (second output view). If you do not provide any Output fields, all the columns are visible in the output. If you provide output fields, we recommend you to select this checkbox.
Default value: Deselected |
|
Match data types
Checkbox |
Conditional. This property applies only when the Output fields property
is provided with any field value(s). If this property is selected, the Snap tries to
match the output data types same as when the Output fields property is empty (SELECT
* FROM ...). The output preview would be in the same format as when accessing all
the columns. Default value: Deselected |
|
Query band
String/Expression |
Specify the name-value pairs to use in the session's generated query band statement. The query band is passed to the Teradata database as a list of name-value pairs separated by semi-colons.
Default value: N/A Example: ProjectName=dstage1;user=test; |
|
Number of retries
Integer |
The number of retry attempts the Snap makes in case of a connection failure. Default value: 3 |
|
Retry interval (seconds)
Integer |
The interval in seconds between retry attempts. Default value: 1 |
|
Staging mode
Dropdown list |
Required if the value in the Number of retries field is greater than 0. Specify the location to store input documents between retries, from the following options:
To disable staging, enter 0 in the Number of retries field. Default value: In memory Example: On disk |
|
| Fast Export | Configure the FastExport settings for data export. | |
File Action
Dropdown list |
Required. Select an action to take when the specified file already exists in the directory. Options available include:
Default value: Error Example: Overwrite |
|
FEXP Location
String/Expression |
The location of the Teradata FastExport component.
Default value: /usr/bin/fexp Example: /opt/teradata/client/bin/fexp |
|
Character Set
Dropdown list |
Select the character set in which data should be encoded when you export data from the Teradata Database. Teradata Database allows a character set to be established when invoking the FastExport. The available options are:
Default value: Default Example: UTF-8 |
|
Output File
String/Expression |
Location of exported data file. If there is a white space, then the path should be in quotes as per the Teradata documentation.
Default value: N/A Example: /data/exports/output.txt |
|
Data Format
Dropdown list |
Export file format. Possible values are:
See the Format Syntax Element for the EXPORT command in the Teradata FastExport Reference for detailed information. Default value: FASTLOAD Example: TEXT |
|
Date format
Dropdown list |
Required. Date format used in the output file in text mode. Options available include:
Default value: Integer Example: Text |
|
Snap execution
Dropdown list |
Choose one of the three modes in
which the Snap executes. Available options are:
|
|
Troubleshooting
| Error | Cause | Resolution |
|---|---|---|
| Failure: TPT script failed to execute error code: 8 |
The Snap is unable to read the Fastload absolute path. | Leave the field blank or update the Fastload absolute path with .exe extension to prevent your pipeline from failing. For example, if you used /usr/bin/fastload as the Fastload absolute path, change it to /usr/bin/fastload.exe. |
| Failure: Failed to execute query error code: 5992 |
A syntax error was found in the QUERY_BAND. | Check that the query band is in the form specified in the Query band field above. For example, if you used priority=1;workload=high in the Query band, add a semi-colon and update the value to priority=1;workload=high;. |