Position - Teradata Warehouse Miner

Teradata Warehouse Miner User Guide - Volume 2ADS Generation

Product
Teradata Warehouse Miner
Release Number
5.4.4
Published
July 2017
Language
English (United States)
Last Update
2018-05-03
dita:mapPath
fcf1492702067123.ditamap
dita:ditavalPath
ft:empty
dita:id
B035-2301
Product Category
Software

The standard string Position function is supported for determining the position of a substring within a string. The SQL generated is POSITION(expression1 IN expression2) where expression1 is the substring and expression2 is the string. The two String expressions must both evaluate to a character, numeric or date type. Numeric or date expressions are converted to characters before evaluating. The type returned is integer. The position returned is the logical position, not the byte position. The first position in a string is treated as 1 and 0 is returned when the substring is not in the string. When dragging a Position operator into a variable, the following tree element is created.

Variable Creation > Input > Variables: SQL Elements pane - String Functions > Position

Columns and/or other expressions can be moved into the (empty) branches of the tree where the first argument is expression1 as indicated above, and the second expression2.

There are no special properties for the Position operator.