The *CONCAT built-in function provides the means of joining or concatenating two discrete strings of data into a single string.
For more information on concatenating numeric data without conversion to character data, see this topic, Convert Variable.
There are four parameters for this function type.
The following three conditions are supplied with the *Number of blanks
parameter.
|
Condition |
Result |
|---|---|
|
*None |
No blanks between the two strings |
|
*One |
Single blank between the two strings |
|
*All |
Retain all trailing blanks of the first string |
CA 2E implements the *CONCAT built-in function as an RPG CAT statement. In COBOL CA 2E implements the *CONCAT function as a STRING statement.
The following example shows a concatenation function that concatenates the fields Name and Last Name and does not put any blanks between the two strings.

The following example shows how the concatenation appears in the Action Diagram:

| Copyright © 2011 CA. All rights reserved. | Tell Technical Publications how we can improve this information |