View previous topic :: View next topic
|
Author |
Message |
shanth555
New User
Joined: 17 Aug 2012 Posts: 35 Location: India
|
|
|
|
How to make String continuation in JCL for 3 or more lines.
Code: |
IFTHEN=(WHEN=(43,7,CH,EQ,C'LATERSP'),
OVERLAY(67:C'THE GETCMX PROGRAM IS CHECKING TO SEE IF THE X
RESPONSE IS WITHIN THE TIMEOUT PARAMETER IF IT ISNT X
THEN IT IS LOGGED AS A LATERSP.')),
|
The above piece of code gives Max 16. |
|
Back to top |
|
|
Akatsukami
Global Moderator
Joined: 03 Oct 2009 Posts: 1788 Location: Bloomington, IL
|
|
|
|
How to recognize JCL (hint: that's not JCL, no matter what some ignorant instructor told you). |
|
Back to top |
|
|
Bill Woodger
Moderator Emeritus
Joined: 09 Mar 2011 Posts: 7309 Location: Inside the Matrix
|
|
|
|
Code: |
OVERLAY=(67:C'THE GETCMX PROGRAM IS CHECKING ',
C'TO SEE IF THE ',
C'RESPONSE IS WITHIN THE TIMEOUT ',
C'PARAMETER ',
C'THEN IT IS LOGGED AS A LATERSP.')) |
Although it is possible to contrinue SORT Control Cards, why make a rod for anyone's back by doing so? Just use multiple literal constants. |
|
Back to top |
|
|
jerryte
Active User
Joined: 29 Oct 2010 Posts: 202 Location: Toronto, ON, Canada
|
|
|
|
What you have shown are control statements for a SORT utility. Bill's suggestion to use mutiple literals is the best way to go.
It is possible to continue a statement by putting a nonblank character in column 72 and then continuing on the next line starting at column 16. The DFSORT manual chapter 3 "General Coding Rules" describes this. |
|
Back to top |
|
|
shanth555
New User
Joined: 17 Aug 2012 Posts: 35 Location: India
|
|
|
|
Hi Jerryte,
The DFSORT rules is working when there are two lines.
i.e : in first line i coded till 71 and 'X' 72 & continued the on the next line starting on 16 column.
When 3 line continuation required - I tried the same by giving 'X' at 72 column of 2nd row & continued the on the next line starting on 16 column.
But it gave RC-0016. Continuation syntax error. |
|
Back to top |
|
|
Bill Woodger
Moderator Emeritus
Joined: 09 Mar 2011 Posts: 7309 Location: Inside the Matrix
|
|
|
|
You have two choices. You can use a trailing comma to indicate a continuation, which is flexible, understandable, and works exactly like your existing control cards. Or you can take the stupid route and waste your time.
To some extent it is your choice. On the other hand, someone is paying for your time, and should not be happy if they were to discover what you were spending it on.
"What did you do yesterday?"
"I was trying to get a continuation to work"
"What else?"
"Well, nothing much, it is very difficult. It will make the code more difficult to maintain, so I need to get it right. There is an easy way, but that is too simple for a professional".
Topic locked. |
|
Back to top |
|
|
Bill Woodger
Moderator Emeritus
Joined: 09 Mar 2011 Posts: 7309 Location: Inside the Matrix
|
|
Back to top |
|
|
Arun Raj
Moderator
Joined: 17 Oct 2006 Posts: 2481 Location: @my desk
|
|
|
|
Syncsort manual wrote: |
If the control statement does contain a literal string that would extend beyond column 71, place a continuation character in column 72 and begin the continuation of the literal string in column 16 of the next card image. |
Example:
Code: |
COL.16 COL.72
↓ ↓
OUTFIL OUTREC=(1:10,8,30:40,10),HEADER2=(1:'CUSTOMER NUMBX
ER',30:'ITEM NUMBER') |
|
|
Back to top |
|
|
Bill Woodger
Moderator Emeritus
Joined: 09 Mar 2011 Posts: 7309 Location: Inside the Matrix
|
|
|
|
Code: |
OUTFIL BUILD=(10,8,
30:40,10),
HEADER2=(01:'CUSTOMER NUMBER',
30:'ITEM NUMBER') |
Now you can change 10 to 9 without having to re-arrange. |
|
Back to top |
|
|
|