This action might not be possible to undo. Are you sure you want to continue?
To share the open data path by various programs in a same job. 2. What is the difference between array and a multiple occurrence data structure? The values stored in array don t vary. In the other hand, we can store the Different values in same variables at various stages. 3. What is *INZSR used for? 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. 4. How can you execute a command from within an RPG program without calling a CLP program? By calling QCMDEXC application program interface we can execute a CL command with in an RPG program. 5. What is the purpose of the "N" in the following calculation specification? 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. 6. Which of the following operations does NOT zero the field FLDA defined as 4,0? C MOVE *ZEROS FLDA C Z-ADD *ZEROS FLDA C Z-ADD 0 FLDA C MOVE *ALL'0' FLDA C SUB FLDA FLDA C MOVE '0000' FLDA C CLEAR FLDA C MOVE *BLANKS FLDA
The last instruction does NOT zero the field FLDA. 7. How can you check for a records existence without causing and I/O (CHAIN/READ)? With the help of File Information Data Structure, we can check existence of records in a physical file. The code is described below:
In File description continuation line (IPFK). Define the RCVF command? RCVF command used to receive the records either from the data base file or device file. 11. variable to store the information to be sent. 8. Example: a new and unique customer number is generated whenever a new customer i added to customer master file. What is the purpose of the following? I 'CLOSED' C STAT01 I 'OPEN' C STAT02 It is a type of initializing the variables in I-spec. Through program we can access new customer number. Define what a data queue is along with a brief example of what it may be used for? Data queues provides communication between programs by calling API's QSNDDTAQ and QRCVDTAQ along with parameters like data queue name. Define the purpose of the %SST function? To extract the information from the specified string. Define what a data area is along with a brief example of what it may be used for? Data area is a storage area to store limited information. Data area keeps track of last record added and add 1 to it. What is the difference between UDATE and the system date? UDATE supports two-digit year. 15. library in which data queue exists. 10. *DATE (system date) supports four digit year. and these are further used in C-spec. 13. STRISDB. 12. The format is *MDYY (MMDDYYYY). . List some of the commonly used commands for debugging STRDBG(for batch jobs). The format is *MDY (MMDDYY). Define the purpose of the *CAT function? To concatenate the two strings into a one string. variable to store the number of characters to be sent. 9. KINFDS RCDS IRCDS DS I *RECORD #RCDS with the above code we can check the existence of records in a file without causing I/O operation. 14. We can send the same data queue to the many programs.
If the file ORDHDR does exist. Define the purpose of the *BCAT function? To concatenate the two strings by placing a single blank in a resultant. The file ORDHIST may or may not exist c. then only the group of instructions allowed executing. CPYF FILE (ORDHDR) TOFILE (ORDHIST) CRTFILE (*YES) c. 17. Purpose of renaming is: If the record format name is similar in two files and if both are used in a same program. the control transfers to the statement below the ENDDO. 18. the program will not compile. CPYF FILE (ORDHDR) TOFILE (ORDHIST) *REPLACE 21. CPYF FILE(ORDHDR) TOFILE(ORDHIST) b.16. What is the purpose of the following? FORDHDR1 IF E K DISK ORDHDRF KRENAMEORDHDRF1 In order to rename the record format of a data base file in a program. it will execute at least one time. it may or may not contain data d. Define the purpose of the ITER operation? If you specify the ITER. DOUxx : Irrespective of condition. 20. CPYF FILE (ORDHDR) TOFILE (ORDHIST) *ADD d. Copy data from the file ORDHDR into file ORDHIST b. 19. Describe the difference between the DOWxx and DOUxx operations? DOWxx : If the condition becomes true. if the file does contain data the old data should be erased Commands: a. we can use the above steps. . List the steps/commands necessary to accomplish the following: a. The file ORDHIST may or may not contain data. Hence we have to rename either of the file. Define the purpose of the LEAVE operation? If you specify LEAVE. the groups of statements are allowed to execute repeatedly.
26. Where as /COPY is compiler directive statement. Define what the operation will do. $2SFN is a relative record number and FMT2 is name of the subfile record format. The letter "U" indicates that the defined data structure is a data area data structure. Define the purpose/use for SFLRNA? Using this. 25. The program sends output after setting the cursor location. we can make specified subfile record format inactive. you can specify cursor location on an output operation to the record format you are defining. 23.ORDERR During the compilation the source code of ORDERR copy book is copied into the existing program. 28.spec. What is the purpose of the following C/COPY QRPGSRC. SFLINZ : First it clears the subfile and initiliazing the numeric variables with zeros and alphanumeric variables with characters. Where as U indicates data area data structure? The above code is used to update the data area value through the program. What is the purpose of the following? A CSRLOC (F1ROW F1COL) Using this record level keyword. 24. What is the purpose of the following I UDS I 1 60ORDER# I 7 90LINE# The purpose is to define the variables in I-Spec and these are further used in C. 27.22. What is the purpose of the following FORDHDR1 CF E WORKSTN $2SFN SFILE FMT2 The above line indicates that. What is the difference between SFLCLR and SFLINZ? SFLCLR : It clears the subfile. the purpose of the result field and the purpose of *IN66? .
32. call the program and pass the parameter. Define each of the following operation codes a. . the program will ended abnormally. 33. With the help of File Information Data Structure we can handle record lock situation. 32. we can get system defined message i. How can you detect overflow for a print program that prints multiple lines per . it reads the records from the data base file based on indicator specified on HI position. 29. Generally it will happen. We can use at all the times. When would you use or not use this approach? SFLSIZ > SFLPAG. e. 31. when the same file of type " U" used in different programs. When would you use or not use this approach? It is the most desirable method in building a real time applications. 34.HI LO EQ C CALL 'CVTDAT' DTPRM 66 The above statement causes. REDEP To read the equal key previous records. b. Otherwise. 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 Whenever the indicator *IN66 becomes *OFF. then only CALL statement will execute. READ To read the records sequentially. the control transfers after ENDDO statement. How do you set the keywords SFLSIZ and SFLPAG if you want the subfile to dynamically expand? SFLSIZ > SFLPAG. READP To read the previous records d. READC To read the records from the workstation file (Subfile). 30. e. Define the purpose of the following code (If you know. READE To read the equal key records c. How can you detect and handle a record lock situation? If you try to read the locked record. If the specified indicator on LO position becomes *OFF.
How would you design the process for a nightly. high volume check producing process that needs to select only records that are flagged to be processed . This indicator automatically set on whenever overflow occurs on a type of page.cycle? You specify the indicators OA through OG and OV in 33 .34 columns in a printer file. 35.
This action might not be possible to undo. Are you sure you want to continue?
We've moved you to where you read on your other device.
Get the full title to continue reading from where you left off, or restart the preview.