Page 1 of 1

Interview Question

PostPosted: Wed May 30, 2012 1:48 pm
by sinmani
1. Suppose I have a Program A and another progam B.
It is known that Program A calls program B. But I do not have the source with me.
So how can I find out whether the call is static or dynamic.

Ans : Don't know.

2. What happens if I do not pass length of data while passing data using PARM parameter from JCL to program.

Ans : Defualt 100 lentgh considered.

3. what happens if I do not define length parameter in the linkage section while passing data
from JCL to program using PARM parameter.

Ans : Defualt 100 lentgh considered.

4. suppose I position my cursor at a partiicular field by using any one of the ways ( using CURSOR command, or moving -1 to the length of the respective
field or using IC option ) but still the cursor is not positioned at that field.
What could be the possible problem??

Ans : Don't know.

Seniors could you please provide some answers

Re: Interview Question

PostPosted: Wed May 30, 2012 2:38 pm
by BillyBoyo
1. Look at the output from the linkedit/binder or, if not available as well as the source, run AMBLIST for the load-module in question and look at that output. There are ways by browsing the loadmodule.

2. Since the operating system does all the "passing" when you specify a PARM in the JCL, the question is meaningless as stated.

3. At the very "best" you will "loose" the first two bytes of your data and have unwanted data depending on how you've defined your field. At worst, if trying to use the length, you'll get an abend (S0C4 is most likely) or you'll pick up, and probably truncate later, a lot of irrelevant stuff, and loose the first two bytes of your data.

4. Not a clue.

Re: Interview Question

PostPosted: Thu May 31, 2012 4:09 pm
by sinmani
BillyBoyo wrote:1. Look at the output from the linkedit/binder or, if not available as well as the source, run AMBLIST for the load-module in question and look at that output. There are ways by browsing the loadmodule.


What is AMBLIST ??

look for what in the output??? What will tell us that it is dynamic or statuc call?? What is value for static and what for dynamic??

Could you please clarify??

Re: Interview Question

PostPosted: Thu May 31, 2012 4:22 pm
by Robert Sample
AMBLIST is an IBM utility program (hence available at all sites) which lists information about load modules, including the Assembler CSECTs that make up the load module. A statically called program will be included in the load module and hence will show up on the AMBLIST output.