1.how do you handle exceptions in PLI? Using On error codes
2.Difference between verify and index? Both return positions of data not existing in second variable
Diff is in o/p. verify returns first char of x not in y. Index returns number of positions of y in x
3.what is control keyword in pli? Controlled is one of the storage classes. It can be used to allocate variable memory as and when it is used.
4.what are the the different types of string functions in pli? Strcp,strcmp,substr,translate,verify
5.how do you write from pli code to jcl?
6.what is the entry statement ?where we use; Entry structure/variables/procedures are defined in predefined libraries, these can be used in our app pgm by coding ENTRY stmt
7.where we use BASED? what is the purpose; based var is used for ADDressing memeory of the variable/structure. This is one of the types in pl1 to redefine the memory area.
8.default variable declaration? automatic
9.what is the use to declare variable as external?
10.write syntax to declare dynamic array? DCL abc(*) char(4);
11.what is the scope of the variable if it is inside the procedure? fixed
12.how to find a program as a static or dynamic?
13.what is subroutine? X n y are two pgms; x calls y; y executes and control passed back to x;
14.what is fetchable?why we use fetchable;
15.difference between call by name and call by reference?
16.how to include copybook? By using the %INCLUDE stmt
17.what is the different types of storage class? Auto/based/controlled/static
18.which proc execute when compile a pli program? Main
19.how do know it is pli? *PROCESS/Block structure
20.in options (main) , what is meaning of main . if u not used main what will happen? After compiling, os will not understand where to load and execute from
21.difference between steam i/o and record i/o? which one u will prefer and why?
Stream i/o is for small amounts of data i.e., for getting info from sysin or so..; i/p data is not converted to upper case in stream i/o
Record i/o: for larger data intake into app pgm/write to file in jcl.
22.In ON ERROR statement how to allow the system action? On error system
Joined: 23 Nov 2006 Posts: 19270 Location: Inside the Matrix
When you hae a question, you should start a new topic for your question rather tha posting a reply to a tpic that has been inactive for over a YEAR. . .
When posting interview questions about which you are unsure, you need to post the answer you gave and why this was your answer. Someone will be able to either confirm your answer or explain where you were incorrect.