AS/400 Interview Questions Answers: Part 2

12/16/2009 No Comment

IBM AS/400 Interview Questions Answers.

What is the difference between SFLCLR and SFLINZ?
Answer : SFLCLR : It clears the subfile. SFLINZ : First it clears the subfile and initiliazing the numeric variables with zeros and alphanumeric variables with characters.

Define the purpose/use for SFLRNA?
Answer : Using this,we can make specified subfile record format inactive.

What is the purpose of the following
I UDS
I 1 60ORDER#
I 7 90LINE#
Answer :
The purpose is to define the variables in I-Spec and these are further used in C-spec. Where as ‘U’ indicates data area data structure? The above code is used to update the data area value through the program. The letter "U" indicates that the defined data structure is a data area data structure.

What is the purpose of the following?
A CSRLOC (F1ROW F1COL)
Answer :
Using this record level keyword, you can specify cursor location on an output operation to the record format you are defining. The program sends output after setting the cursor location.

Define what the operation will do, the purpose of the result field and the purpose of *IN66?
HI LO EQ
C CALL 'CVTDAT' DTPRM 66
Answer :
The above statement causes, call the program and pass the parameter.

Define each of the following operation codes
a. READ To read the records sequentially.
b. READE To read the equal key records
c. READP To read the previous records
d. READC To read the records from the workstation file (Subfile).
e. REDEP To read the equal key previous records.

Define the purpose of the following code (If you know, how would this be written in RPG ILE)
HI LO EQ
C *IN66 DOUEQ *OFF
C KEY1 CHAIN FILEA 90 66
C 66 CALL PGM1 PRM
C ENDDO
Answer :
Whenever the indicator *IN66 becomes *OFF, the control transfers after ENDDO statement. Otherwise, it reads the records from the data base file based on indicator specified on HI position. If the specified indicator on LO position becomes *OFF, then only CALL statement will execute.

How do you set the keywords SFLSIZ and SFLPAG if you want the subfile to dynamically expand?
Answer 
: SFLSIZ > SFLPAG.

When would you use or not use this approach?
Answer :
It is the most desirable method in building a real time applications. We can use at all the times.

How can you detect and handle a record lock situation?
Answer :
If you try to read the locked record, we can get system defined message i. e. , the program will ended abnormally. With the help of File Information Data Structure we can handle record lock situation. Generally it will happen, when the same file of type " U" used in different programs.

How can you detect overflow for a print program that prints multiple lines per cycle?
Answer :
You specify the indicators OA through OG and OV in 33 - 34 columns in a printer file. This indicator automatically set on whenever overflow occurs on a type of page.

Define a shared access path?
Answer :
To share the open data path by various programs in a same job.

What is the difference between array and a multiple occurrence data structure?
Answer :
The values stored in array don’t vary. In the other hand, we can store the
Different values in same variables at various stages.

What is *INZSR used for?
Answer :
It is special type of RPG/400 subroutine, which is executed automatically
at beginning of the program. It is a good place to code initializes the variables.

How can you execute a command from within an RPG program without calling a CLP program?
Answer :
By calling QCMDEXC application program interface we can execute a CL command with in an RPG program.

What is the purpose of the "N" in the following calculation specification?
Answer :
C KEY CHAIN FILE N 99.If you specify 'N' in 53rd position, the record will not be locked if you try to read the locked record. It is a way of avoiding the record lock.
Related Posts


No comments :

 

Aired | The content is copyrighted and may not be reproduced on other websites. | Copyright © 2009-2016 | All Rights Reserved 2016

Contact Us | About Us | Privacy Policy and Disclaimer