RPLSTRIFS, replace character string in input file
Usage
The RPLSTRIFS command can be used to replace a string in the input file with another value.
Parameters and their meaning
The command has the following parameters
Parameter | Element | Value | Description |
|---|---|---|---|
FRMPATH | Name of the input path in the IFS file system. If the command is defined in the i-effect *SERVER *IFS server entry as a *USERDEFINED | ||
FRMIFSFILE | Name of the input file in the IFS file system without path. If the command is defined in the i-effect *SERVER *IFS server entry as *USERDEFINED | ||
FRMCCSID | The CCSID of the input file. The default is 1252. | ||
CASE | *YES | Uppercase and lowercase letters are distinguished | |
*NO | Uppercase and lowercase letters are not distinguished | ||
REPLACE | Here you can specify which search patterns are replaced with which values in the input file. Up to 50 replacement rules can be defined here. | ||
Element 1 | This element defines a search pattern that is searched for. | ||
HEXSuchmuster | By specifying the character string HEX before the actual search pattern, the character string to be searched for can be specified in hexadecimal notation. To replace a ';' character at the end of a line (hexadecimal value x'540d25') with a line feed (hexadecimal x'0d25'), the following parameter definition can be used:
CODE
To remove a line feed, the following parameter definition can be used:
CODE
| ||
Element 2 | This element defines the replacement string with which each string value found in element 1 is replaced. | ||
HEXZeichenkette | By specifying the character string HEX before the actual replacement string, the replacement can be specified in hexadecimal form.
CODE
| ||
*CRLF | The string found is replaced with a line feed (CRLF).
CODE
| ||
*ADDCRLF | A line feed (CRLF) is added to the found string.
CODE
| ||
USESEPCHAR | This parameter is no longer used and will be removed in a future version. | ||
USEBUFFER | This parameter is no longer used and will be removed in a future version. |
Examples of use
Description | Command parameter definitions |
|---|---|
EReplaced the string ENACOM with the string UN in the input file. |
CODE
|
Replacing the EBCDIC character (x'5E') with the EBCDIC characters for line feed (x'5E0D25') |
CODE
|
Removing a line feed character (x'0D25') from a file |
CODE
|