Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
Usage of COBOL linkage length variable.

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> COBOL Programming
View previous topic :: :: View next topic  
Author Message
somnath

New User


Joined: 21 Mar 2005
Posts: 18
Location: India

PostPosted: Wed May 30, 2007 6:17 pm    Post subject: Usage of COBOL linkage length variable.
Reply with quote

Can somebody help me out on the following:

While Passing the PARM from the JCL to a Cobol program we declare the Length of the Parm in the Linkage as a variable.

What is the use of this Length variable? Why do we need to specify it?
What can be the Maximum length of the Parm field?
If we don't specify the Length field will it cause any abend? If so what type of abend will be generated?

________
Somnath
Back to top
View user's profile Send private message

krisprems

Active Member


Joined: 27 Nov 2006
Posts: 649
Location: India

PostPosted: Wed May 30, 2007 9:08 pm    Post subject:
Reply with quote

check this link
http://www.davar.net/MF/REFER/CODE.HTM#Continue_PARM_
Back to top
View user's profile Send private message
somnath

New User


Joined: 21 Mar 2005
Posts: 18
Location: India

PostPosted: Thu May 31, 2007 11:25 pm    Post subject:
Reply with quote

Thanks Krisprem.
I got the answer for the Maximum length of the parm. Can u please let me know the rest?
Back to top
View user's profile Send private message
William Thompson

Global Moderator


Joined: 18 Nov 2006
Posts: 3158
Location: Tucson AZ

PostPosted: Fri Jun 01, 2007 4:38 am    Post subject: Re: Usage of COBOL linkage length variable.
Reply with quote

somnath wrote:
While Passing the PARM from the JCL to a Cobol program we declare the Length of the Parm in the Linkage as a variable.
Well, how else would you know how long it was?
Quote:
What is the use of this Length variable? Why do we need to specify it?
Because it is being passed to you and you need to know the length of the data being passed to you.
Quote:
If we don't specify the Length field will it cause any abend? If so what type of abend will be generated?
If you don't specify the length, you will have garbage in the first couple bytes and might get a S0C4 if you reach too far.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> COBOL Programming All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Moving a COMP-3 Variable to a Numeric... ajayachander COBOL Programming 2 Thu Dec 14, 2017 5:46 pm
This topic is locked: you cannot edit posts or make replies. Cobol to fetch the content by using s... arunc55 COBOL Programming 4 Fri Nov 17, 2017 1:25 pm
No new posts VBS and VB, COBOL syntax is the same ... natt.sut COBOL Programming 3 Sun Nov 12, 2017 6:36 am
No new posts how can i move s9(9) to s9(9) usage comp HARENDRA CHOUDHARY COBOL Programming 3 Mon Nov 06, 2017 12:10 am
No new posts Move from Comp3 variable to Edited Va... Revathy.nair0485 COBOL Programming 7 Fri Nov 03, 2017 3:30 pm

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us