Your Browser is not longer supported

Please use Google Chrome, Mozilla Firefox or Microsoft Edge to view the page correctly
Loading...

{{viewport.spaceProperty.prod}}

@GETJV - Read value of job variable

&pagelevel(3)&pagelevel

The @GETJV statement outputs the value of a job variable on the screen, writes it to a work file or assigns it to a string variable.

Operation

Operands

F mode, L mode

@GETJV

[string] [={line | svarex}] [,CODE=name]

string

String which specifies the fully qualified name of a job variable. Although the
name must comply with the syntactic rules for job variable names, EDT
does not check these rules in full. If string is not specified then the job
variable is addressed using the file link name *EDTLINK. If this is not
defined then the message EDT5289 is output.

lineNumber of the line to which the value of the job variable is to be written.
svarexString variable in which the value of the job variable is to be written.

name

Name of the character set in which the value of the job variable is to be
interpreted. The character set must be valid; otherwise, the statement is rejected
with message EDT4980. If the operand is not specified, the value of the job
variable is interpreted in the character set EDF041 (see section “Charactersets”).

If neither line nor svarex is specified, the value of the job variable is output to SYSOUT in interactive mode and to SYSLST in batch mode.

If a line with a number greater than the previous highest line number is created then the current line number is modified.

If the job variable does not exist then the message EDT4982 is output. If it cannot be accessed then the message EDT4208 is output.

If the job variable is empty then an empty string is used as its value.

If the job variable contains an invalid byte sequence (possible in Unicode character sets) then it is not read and the message EDT5454 is output.

If it is assigned to a string variable then this is also assigned the character set specified implicitly or explicitly via name. If it is inserted in a work file then the value is converted into the work file's character set. If the work file is empty and has the character set *NONE then it is assigned the character set specified explicitly or implicitly via name. If the string that is to be assigned contains characters which cannot be converted into the work file's character set then these characters are replaced by a substitute character provided that such a character has been specified (see @PAR SUBSTITUTION-CHARACTER); otherwise, the string is not assigned and the error message EDT5453 is output.

If the Job Variable Support subsystem is not installed, the statement is rejected with the error message EDT5254. For details concerning job variables, see the User Guide JV [9].