IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

How to pass the 10 bytes value to COBOL called program


IBM Mainframe Forums -> Mainframe Interview Questions
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
raman.k

New User


Joined: 26 Feb 2007
Posts: 24
Location: chennai

PostPosted: Mon Mar 26, 2007 7:06 pm
Reply with quote

Hi
I attend one interview. the interviewer asked the question how to pass the 10 bytes value to COBOL program
I told like.
i declare the variable in LINKAGE SECTION then i Mention in PROCEDURE DIVISION USING A.

He told it is wrong.
I don't how to pass this value


Please tell me
Raman.l
Back to top
View user's profile Send private message
raman.k

New User


Joined: 26 Feb 2007
Posts: 24
Location: chennai

PostPosted: Mon Mar 26, 2007 7:20 pm
Reply with quote

raman.k wrote:
Hi
I attend one interview. the interviewer asked the question how to pass the 10 bytes value from JCL to COBOL called program
I told like.
i declare the variable in LINKAGE SECTION then i Mention in PROCEDURE DIVISION USING A.

He told it is wrong.
I don't how to pass this value


Please tell me
Raman.l
Back to top
View user's profile Send private message
William Thompson

Global Moderator


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

PostPosted: Mon Mar 26, 2007 8:29 pm
Reply with quote

To pass it down to the called program, you just reference your (the calling) program's working storage in the CALL verb, i.e., "CALL SUBROUTINE USING WS-DATA-AREA".
Your original answer was more on the mark for the called program rather than the calling program.
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Mon Mar 26, 2007 10:18 pm
Reply with quote

Hello,

If this was a JCL question, the answer would include using a PARM on the EXEC for the COBOL program along with the LINKAGE/PROCEDURE considerations.

Was the interviewer knowledgeable about COBOL/JCL or was it a personnel/hr person who had a list of questions and was told what to accept as answers.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> Mainframe Interview Questions

 


Similar Topics
Topic Forum Replies
No new posts Replace each space in cobol string wi... COBOL Programming 3
No new posts Using API Gateway from CICS program CICS 0
No new posts COBOL -Linkage Section-Case Sensitive COBOL Programming 1
No new posts COBOL ZOS Web Enablement Toolkit HTTP... COBOL Programming 0
No new posts Calling DFSORT from Cobol, using OUTF... DFSORT/ICETOOL 5
Search our Forums:

Back to Top