Using "AND" on DO STATMENT ?
Using "AND" on DO STATMENT ?
Hello, I am new here !
I would like to know if it is possible (and how) to use a 'AND' in DO Statment.
In STEP, my ON OK condition should meet 2 conditions :
- My JOB exists with a COMPLETED statment
ON Statment (Stm = *) Code = (COMPLETED)
- My job exists with a code < 5
ON Statment (Stm = *) Code = (COMPSTAT < 5)
But I am not able to use BOTH of these conditions.
CTM will ended with a SUCCESS on one of these conditions fullfilled.
Any help ?
Thanks,
Cédric from Paris, France
I would like to know if it is possible (and how) to use a 'AND' in DO Statment.
In STEP, my ON OK condition should meet 2 conditions :
- My JOB exists with a COMPLETED statment
ON Statment (Stm = *) Code = (COMPLETED)
- My job exists with a code < 5
ON Statment (Stm = *) Code = (COMPSTAT < 5)
But I am not able to use BOTH of these conditions.
CTM will ended with a SUCCESS on one of these conditions fullfilled.
Any help ?
Thanks,
Cédric from Paris, France
- philmalmaison
- Nouveau
- Posts: 1148
- Joined: 08 Jun 2007 12:00
- Location: Ile de France
to anderstand how control-m work on completion statements and codes, you must read Control-m Job Parameter and Variable Reference guide, on www.bmc.com site.
pages : 256 / 257 / 258 ...
pages : 256 / 257 / 258 ...
I already read this documentation.philmalmaison wrote:to anderstand how control-m work on completion statements and codes, you must read Control-m Job Parameter and Variable Reference guide, on www.bmc.com site.
pages : 256 / 257 / 258 ...
I forgot to say that I am not in z/OS, but in Unix (AiX).
There is no AND or OR conditions between STEP statments...
We are migrating CTM from MVS to Unix.
That is the problem. Indeed in MVS return codes < 5 are OK, not in Unix !
Dont really know how to handle this.
Perhaps, we can echo "COMPLETED RETURN_CODE=XXXXX", and if we are able to catch this RETURN_CODE to a CTM global var, it should be easy to create conditions for OK or NOTOK.
The fact is, at this point, we are even able to make the difference between a return code of 1 issued from CTM (for exemple, if the script to execute is not found) or issued from the end of the script.
Any idea ?
Thanks
Csaliou,
You mention:
We are migrating CTM from MVS to Unix.
That is the problem. Indeed in MVS return codes < 5 are OK, not in Unix !
If this means that there will be no more jobs running on MVS, then you do not need to consider the MVS "only" default (return codes until 4 are OK).
But I don't think that's your case.
If you install Control-M software on UNIX, this implies generally that you will be installing Control-EM (Enterprise Manager) and Control-M server software. The Control-M EM software enables you to graphically see what the batch flows are. It has gateways to the Control-M server software on UNIX systems, AND on MVS systems. The Control-M software on MVS still needs to be installed on MVS.
Now: the templates used for UNIX schedule definitions differs from the tempates used for MVS schedule definitions.
So once you have installed the Control-M software on UNIX, you need to define the gateway to MVS (on UNIX), and on MVS you need to install the so called IOAGATE.
If this is all in place then you probably see the MVS templates and there you will see that you still have the AND/OR possibility.
You mention:
We are migrating CTM from MVS to Unix.
That is the problem. Indeed in MVS return codes < 5 are OK, not in Unix !
If this means that there will be no more jobs running on MVS, then you do not need to consider the MVS "only" default (return codes until 4 are OK).
But I don't think that's your case.
If you install Control-M software on UNIX, this implies generally that you will be installing Control-EM (Enterprise Manager) and Control-M server software. The Control-M EM software enables you to graphically see what the batch flows are. It has gateways to the Control-M server software on UNIX systems, AND on MVS systems. The Control-M software on MVS still needs to be installed on MVS.
Now: the templates used for UNIX schedule definitions differs from the tempates used for MVS schedule definitions.
So once you have installed the Control-M software on UNIX, you need to define the gateway to MVS (on UNIX), and on MVS you need to install the so called IOAGATE.
If this is all in place then you probably see the MVS templates and there you will see that you still have the AND/OR possibility.
- philmalmaison
- Nouveau
- Posts: 1148
- Joined: 08 Jun 2007 12:00
- Location: Ile de France