View previous topic :: View next topic |
Author |
Message |
Dibakar Advanced

Joined: 02 Dec 2002 Posts: 700 Topics: 63 Location: USA
|
Posted: Fri Mar 28, 2003 5:54 am Post subject: |
|
|
Ravi,
I tried your JCL and its working as expected when VAR1 is 1 or 2 or any numeric value. But its giving JCL error when I give any non numeric value, possibly you can't.
Dibakar.
Last edited by Dibakar on Fri Mar 28, 2003 6:16 am; edited 1 time in total |
|
Back to top |
|
 |
Dibakar Advanced

Joined: 02 Dec 2002 Posts: 700 Topics: 63 Location: USA
|
Posted: Fri Mar 28, 2003 6:22 am Post subject: |
|
|
Ravi,
Are you sure both steps got executed?!
When I set VAR1=1, only STEP2 got executed. And I just did a cut and paste of your code (and changed the data set names).
Diba. |
|
Back to top |
|
 |
slade Intermediate
Joined: 07 Feb 2003 Posts: 266 Topics: 1 Location: Edison, NJ USA
|
Posted: Fri Mar 28, 2003 3:47 pm Post subject: |
|
|
Hi Ravi,
I was surprised when I read your post. I was under the impression that JCL "IF" stmts were used only to test system return codeds (RC), ABENDs and step run status (RUN).
You may want to reconsider what you're doing if it's intended to be used in a production environment. I copied the following fron the JCL Reference Manual. IBM has a history of "closing" loopholes like these without warning.
If you only intend to use it for your testing, it's up to you.
Quote: |
You can specify symbolic parameters on IF/THEN/ELSE/ENDIF statements provided that they resolve to one of the supported relational-expression keywords listed in the preceding topic (that is, RC, ABEND, ...). Any other symbolic parameters, even if accepted by the system, are not intended or supported.
|
Regards, Jack. |
|
Back to top |
|
 |
|
|