> -----Original Message----- > From: IBM Mainframe Discussion List > [mailto:ibm-m...@bama.ua.edu] On Behalf Of Donald Johnson > Sent: Wednesday, April 07, 2010 8:49 AM > To: IBM-MAIN@bama.ua.edu > Subject: Use of IF JCL statements > > Hi there! Can some one point me to documentation that would > explain what > happens in a JCL stream with IF/ELSE statements and the job > is trying to be > restarted in the middle? > > For example, if I have: > > Step1 > Step2 > IF Step2.rc <4 Then > Step3 > IF Step3.rc = 0 Then > Step4 > Step5 > ENDIF (step3) > ENDIF (step2) > > And try to restart at Step4, all steps have flushed. I have a > good idea that > it is because the IF tests could not work (there is no > Stepx.RUN), so even > though restarting in Step4, the interpreter knows it is inside the IF > statements. > > Can someone point me in the right direction, so I can help my user? > > Thank you for your assistance! > Don
ref: http://publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/BOOKS/IEA2B690/17.1.4 <quote> If you specify a stepname as part of a relational-expression, the system first determines whether the step executed. If the step did not execute, the evaluation of the relational-expression is false. </quote> >From my intepretation of: "If the step did not execute, the evaluation of the >relational-expression is false.", I think that any relational expression >involving a flushed step evaluates to FALSE. So, in your example, the steps >within the IF would NOT be executed. -- John McKown Systems Engineer IV IT Administrative Services Group HealthMarkets(r) 9151 Boulevard 26 * N. Richland Hills * TX 76010 (817) 255-3225 phone * (817)-961-6183 cell john.mck...@healthmarkets.com * www.HealthMarkets.com Confidentiality Notice: This e-mail message may contain confidential or proprietary information. If you are not the intended recipient, please contact the sender by reply e-mail and destroy all copies of the original message. HealthMarkets(r) is the brand name for products underwritten and issued by the insurance subsidiaries of HealthMarkets, Inc. -The Chesapeake Life Insurance Company(r), Mid-West National Life Insurance Company of TennesseeSM and The MEGA Life and Health Insurance Company.SM ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html