/CUSTOMTASK - Connect_ETL - 9.13

Connect ETL Data Transformation Language (DTL) Guide

Product type
Software
Portfolio
Integrate
Product family
Connect
Product
Connect > Connect (ETL, Sort, AppMod, Big Data)
Version
9.13
Language
English
Product name
Connect ETL
Title
Connect ETL Data Transformation Language (DTL) Guide
Copyright
2023
First publish date
2003
Last updated
2023-09-11
Published on
2023-09-11T19:01:45.019000

Purpose

To define a custom task.

Format

/CUSTOMTASK [ALIAS alias] EXECUTABLE executable [ARGUMENTS arguments] [sources] [targets] [SUCCESSIF status] [EXECUTIONTAG tag]

where

sources = SOURCES source [,source…]
source = {STDIN } {NAMEDPIPE platformpipe_name}
targets = TARGETS target [,target…]
target = {STDOUT } {NAMEDPIPE platform pipe_name}
platform = {WINDOWS} {UNIX }
status = {EXITSTATUS comparison_operator numeric_value} {ALWAYS }
comparison_operator = {= } equals {!=} does not equal {> } greater than {>=} greater thab or equal to (not less than) {< } less than {<=} less than or equal to (not greater than)

Arguments

executable the pathname of the custom executable to run. For details on specifying a file path, see File Name and Syntax Requirements.
arguments a character string indicating the arguments, separated by spaces, passed to the executable.
alias a name you assign to the custom task, and which you use to refer to the task in other Data Transformation Language options. The name assigned to the task must adhere to the rules described for an identifier. For details on specifying a file name, see File Name and Syntax Requirements.
pipe_name the pathname of the local or remote named pipe. On Windows systems, this is specified as \\<server>\pipe\<actual_pipe_name>. For details on specifying a file path, see File Name and Syntax Requirements.
numeric_value a number to compare the the exit status of the executable against, to determine the completion status of the custom task.
tag a character string you assign to the custom task that specifies an execution framework on which to run it.

Location

The option may appear anywhere in the job definition.

Notes

The same custom task executable can be defined multiple times in the job definition.

When specifying multiple instances of the same custom task executable in the job, aliases need to be provided to make the task definition unambiguous. For example, if the first instance of a custom task definition does not have an alias, all subsequent definitions must have an alias specified.

Custom tasks cannot have multiple named pipes defined as sources or targets. Standard input (or output) can however be used in addition to a named pipe as a source (or target) of records.

Examples

/CUSTOMTASK EXECUTABLE echo ARGUMENTS "One Two Three"
This custom task invokes the echo command with the arguments "One Two Three".
/CUSTOMTASK EXECUTABLE cat SOURCES STDIN, NAMEDPIPE UNIX /pipe1
This custom task invokes the cat command with the contents of standard input and the pipe /pipe1 as the sources of records.
/CUSTOMTASK EXECUTABLE cat ARGUMENTS """c:\program files\file1.dat"" ""c:\program files\file2.dat"""

This custom task invokes the cat command with file names that require quotes since they have a space in their path. These quotes need to be escaped.