As mentioned above, a Global variable is a user-defined variable that is placed in the IOA Global Variable database.
%%SET statements in the JCL, and SET VAR or DO SET statements in the job scheduling definition, enable Control-M jobs and SMART Table Entities to define Global variables and place them in the IOA Global Variable database. These variables can then be used and accessed by other jobs. These jobs can use %%SET, SET VAR and/or DO SET statements to change or update the variable values in the database.
You can now define some Global variables in the job scheduling definition and JCL of job IDJOB8.
SET VAR %%\VAR1=AAA
SET VAR %%..\VAR2=BBB
SET VAR %%..\IDJOB9\VAR1=CCC
//* VAR1 FROM JOB JOB8 EQUALS %%\VAR1
//* VAR2 FROM GROUP GRP3 EQUALS %%..\VAR2
//* VAR1 FROM JOB JOB9 EQUALS %%..\IDJOB9\VAR1
//* VAR1 FROM JOB JOB8 EQUALS AAA
//* VAR2 FROM GROUP GRP3 EQUALS BBB
//* VAR1 FROM JOB JOB9 EQUALS CCC
From this sysout, you can see that the AutoEdit variables resolved as they should. However, because they appeared in the job scheduling definition and the JCL of the same job, you have not yet demonstrated their global nature.
You will demonstrate the global nature of these variables shortly, but first, take a look at Global variable syntax.
Parent Topic |