Previous Topic

Next Topic

Book Contents

Book Index

Example

In this example, if the account field in the job card is empty, we update it to "0000". If the class is not U or D, we issue an error message. The jobs that are tested are jobs that begin with PAY* and are submitted from the PRD.PAY.ACCOUNT.DAILY.JOBS library from members that begin with DPAY*.

Fig.JV.3.24 DO IF example

 +-----------------------------------------------------------------------------+

 | RULE      DAILYPAY   ENVIRONMENT PROD       PRIORITY 3 CONTINUE SEARCH Y    |

 | DESC        For accounting jobs, enforce account information and            |

 | DESC        class D and U                                                   |

 |=============================================================================|

 | JOBNAME PAY*____            _                                               |

 | LIBRARY  PRD.PAY.ACCOUNT.DAILY.JOBS__________________  MEMBER  DPAY*___     |

 | SCHDLIB                                              SCHDTAB          O/N   |

 |=============================================================================|

 | ON JOB           CLASS         PRTY          USER                           |

 | ACCOUNT                                                               O/N   |

 |=============================================================================|

 | IF %%JOB_ACT EQ ''                                                          |

 | DO MSG  TYPE E Account field is empty.Automatically filled with "0000".     |

 | DO SET  %%JOB_ACT = '0000'                                                  |

 | ENDIF                                                                       |

 | IF %%$JOBCLS NE 'D'                                                         |

 | IF %%$JOBCLS NE 'U'                                                         |

 | DO MSG  TYPE E JOBS of PAYABLE must run with class D or U.                  |

 | ENDIF                                                                       |

 | ENDIF                                                                       |

 |=============================================================================|

Parent Topic

DO IF / DO ELSE / DO ENDIF: Action Parameter