Skip to main content

Celonis Product Documentation

CONCAT
Description

CONCAT and || return the concatenation of two or more strings.

Supported input column types: STRING, INT, FLOAT. INT and FLOAT types are internally automatically converted to STRING before the concatenation is executed. See the examples below how FLOAT values are converted to STRING.

Output column type: STRING

Syntax
 CONCAT ( table.column1, ..., table.columnN )
 table.column1 || table.column2 [ || table.columnN ]*
NULL handling

If at least one value is NULL, the result of the concatenation is NULL.

Examples

[1]

Concatenate column values with constant string.

Query

Column1

         CONCAT ( "Table1"."Column1" , 'berry' )
        

Input

Output

Table1

Column1 : string

'blue'

'black'

'cran'

'huckle'

Result

Column1 : string

'blueberry'

'blackberry'

'cranberry'

'huckleberry'

[2]

Concatenation of 3 strings with ||.

Query

Column1

         "Table1"."Column1" || "Table1"."Column2" || "Table1"."Column3"
        

Input

Output

Table1

Column1 : string

Column2 : string

Column3 : string

'a'

'b'

'c'

' a'

'b '

'd'

''

''

''

null

'a'

'b'

''

null

'c'

null

null

'd'

''

' '

' '

'one'

'two'

'x'

Result

Column1 : string

'abc'

' ab d'

''

null

null

null

' '

'onetwox'

[3]

Concatenation of INT, STRING and FLOAT.

Query

Column1

         "Table1"."Index" || '. ' || "Table1"."Name" || ': ' || "Table1"."Value"
        

Input

Output

Table1

Index : int

Name : string

Value : float

1

'pi'

3.14159

2

'e'

2.71828

Result

Column1 : string

'1. pi: 3.14159'

'2. e: 2.71828'

[4]

FLOAT value conversions

Query

Column1

         '' || "Table1"."Value"
        

Input

Output

Table1

Value : float

0.0

1.0

-0.0

-1.0

Infinity

-Infinity

1000000.0

1.0E7

1.0E8

1.0E9

1.0E10

1.0E11

1.0E12

1.0E13

1.0E14

1.0E15

1.0E16

1.0E17

1.0E100

-1.0E100

4.28347276812974

1.0389472948583984

3.8547398479832944E12

1.00000000000001

1.000000000000001

1.0

1.0

Result

Column1 : string

'0.0'

'1'

'0.0'

'-1'

'Infinity'

'-Infinity'

'1000000'

'10000000'

'100000000'

'1000000000'

'10000000000'

'100000000000'

'1000000000000'

'10000000000000'

'100000000000000'

'1000000000000000'

'1e+16'

'1e+17'

'1e+100'

'-1e+100'

'4.28347276812974'

'1.0389472948583984'

'3854739847983.2944'

'1.00000000000001'

'1.000000000000001'

'1'

'1'

See also: