String Transform

Data in String type can be converted to Date, Decimal, Float, Integer, Time or Timestamp type. You can also perform the following operations:

Add prefix

This operation enables you to specify a prefix and adds it in front of the strings.

InputPrefixOutput
abcXYZXYZabc
defXYZXYZdef

Add suffix

This operation enables you to specify a suffix and adds it at the end of the strings.

InputSuffixOutput
abcXYZabcXYZ
defXYZdefXYZ

Ascii to zenkaku alphanumeric

This operation converts the string encoding from ascii to zenkaku alphanumeric.

InputOutput

Capitalize

This operation capitalizes the first character in each string.

InputOutput
abcAbc
defDef

Contains

This operation returns either true or false depending on whether the string contains the specified substring.

The system performs a case sensitive search of the substring.

InputOutput
Macedonia

The substring to find is 'don'.

true
Macedonia

The substring to find is 'Don'.

false
Australia

The substring to find is 'Don'.

false

Count

This operation counts the number of characters in each string.

InputOutput
abc3
defgh5

Ends with

This operation enables you to specify a suffix, checks if the strings end with this suffix and returns Boolean values (true or false).

InputSuffixOutput
abczfalse
xyzztrue

Enumeration to boolean

Before starting this operation, you must specify nominal or ordinal attributes for the specified field in a processor. These attributes should be values from the field. Create another processor for this operation, and link these 2 processors with the Flow connector.

This operation generates one or more new fields in Boolean type depending on the attributes. New field names will be the same with attribute names. If a row value equals the attribute value, it returns "true". Otherwise it returns "false".

The following table shows an example when the nominal or ordinal attributes are:

US
Mexico
InputUSMexico
UStruefalse
Canadafalsefalse
Mexicofalsetrue

Enumeration to integer

Before starting this operation, you must specify nominal or ordinal attributes for the specified field in a processor. These attributes should be values from the field. Create another processor for this operation, and link these 2 processors with the Flow connector.

This operation generates one or more new fields in Integer type depending on the attributes. New field names will be the same with attribute names. If a row value equals the attribute value, it returns "1". Otherwise it returns "0".

The following table shows an example when the nominal or ordinal attributes are:

US
Mexico
InputUSMexico
US10
Canada00
Mexico01

Extract

This operation enables you to specify a Regular Expression (RegExp) and extract characters from strings according to this expression.

InputRegExpOutput
abcdef..(.*)cdef
uvwxyz..(.*)wxyz

First

This operation enables you to specify a length value and extract the specified number of characters from the beginning of each string.

InputLengthOutput
abcdef2ab
uvwxyz2uv

Hankaku katakana to zenkaku katakana

This operation converts Japanese characters from hankaku katakana to zenkaku katakana.

InputOutput

Hiragana to katakana

This operation converts Japanese characters from hiragana to katakana.

InputOutput

Index of

This operation returns integers that indicate the first occurrence of the specified value in each string. The search proceeds from left to right. Returning "-1" means that the value cannot be found.

InputValueOutput
Appler-1
Berryr2
Oranger1
Strawberryr2

Katakana to hiragana

This operation converts Japanese characters from katakana to hiragana.

InputOutput

Last

This operation enables you to specify a length value and extracts a certain length of characters from the end of each string.

InputLengthOutput
abcdef2ef
uvwxyz2yz

Last index of

This operation returns integers to find out where is the last occurrence of the specified value in each string. Returning "-1" means that the value cannot be found.

InputValueOutput
Appler-1
Berryr3
Oranger1
Strawberryr8

Left pad

This operation enables you to specify a prefix and a length value, and extends the length of strings by repeating the prefix from the left end. If the specified length is smaller than the original length, strings are unchanged.

InputPrefixLengthOutput
abcZ6ZZZabc
defghijkZ6defghijk

Left trim

This operation trims off the extra spaces, tabs and new lines from the left end of strings. For example, you can left trim the string " 2011-10-31" and receive the output "2011-10-31".

Lower

This operation converts the uppercase letters into lowercase.

InputOutput
ABCabc
Defdef

Matches

This operation enables you to specify a Regular Expression (RegExp), checks if the strings match this expression and returns Boolean values (true or false).

InputRegExpOutput
abcd...(.*)true
ef...(.*)false

Merge

This operation merges strings from the specified field by connecting them with a separator, when the corresponding rows from the other fields include exactly the same information. These rows will become one row as a result of merge.

The following table shows an example of the input:

Field 1Field 2Field 3Field 4Field 5
ABC10l
ABC10m
ABC10n
DEF0p
DEF0q

The following table shows an example of the output (Separator: "."):

Field 1Field 2Field 3Field 4Field 5
ABC10l.m.n
DEF0p.q

Null to string

This operation displays the Null strings as a specified value, while the other values remain the same.

InputValueOutput
 XYZXYZ
abcXYZabc

Replace

This operation finds a specified keyword from strings and replaces it with a specified string value.

InputKeywordValueOutput
abcaZZbc
defaZdef

ReplaceRegExp

This operation replaces each substring of the string that matches the given regular expression, with the given replacement string.

The search is case sensitive.

InputRegExpValueOutput
Orange[aeiou]XOrXngX
applE[aeiou]ZZpplE
Mangoostan[aeiou]XMXngXXstXn
MAngoostan[aeiou]XMAngXXstXn

In the above examples, any occurance of the letters a, e, i, o or u are replaced with the specified replacement string.

Right pad

This operation enables you to specify a suffix and a length value, and extend the length of strings by repeating the suffix from the right end. If the specified length is smaller than the original length, strings are unchanged.

InputSuffixLengthOutput
abcZ6abcZZZ
defghijkZ6defghijk

Right trim

This operation trims off the extra spaces, tabs and new lines from the right of strings. For example, you can right trim the string "2011-10-31 " and receive the output "2011-10-31".

Slice

This operation enables you to specify two integer values, which indicate the start and end of the slice operation.

InputFrom, ToOutput
a/b/c1, 3/b
d.e.f1, 3.e

Split

This operation splits strings according to a specified separator, and displays the split characters in separate rows.

The following table shows an example of the input:

Input
a/b/c
X/Y

The following table shows an example of the output (Separator: "/"):

Output
a
b
c
X
Y

Starts with

This operation enables you to specify a prefix, check if the strings start with this prefix and return a Boolean value (true or false).

InputPrefixOutput
abcatrue
defafalse

Trim

This operation trims off the extra spaces, tabs and new lines from both ends of strings. For example, you can trim the string " 2011-10-31 " and receive the output "2011-10-31".

Upper

This operation converts the lowercase letters into uppercase.

InputOutput
abcABC
DefDEF

Zenkaku alphanumeric to ascii

This operation converts the string encoding from zenkaku alphanumeric to ascii.

InputOutput

Zenkaku katakana to hankaku katakana

This operation converts Japanese characters from zenkaku katakana to hankaku katakana.

InputOutput