1) How to declare a file?
2) How to define a display file?
3) How to monitor error messages in RPG?
4) How to find the attributes for subfiles? and what is the
DDS for subfiles?

Answer Posted / madhu

1Ans).DCL VAR(&A) TYPE(*DEC) VALUE(54)
2ans). DCLF FILE(LIBNAME/FILENAME) RCDFMT(SCREEN NAME)
3Ans.) In FREE FORMAT WE ARE USING MONITOR AND END-MON,THE
CODE LIKE MONITOR;
--------
ON-ERROR(FILE NAME/PGM NAME);
---------
END-MON;
AND ALSO IN RPG/400 WE ARE USING *PSSR SUBROTEN WE CAN TRAP
THE ERRORS
AND ALSO WE R USING FILE INFORMATION DATASTRCTERS, PROGRAM
STATUS DATA STRUCTERS WE CAN TRAP THE ERRORS
4Ans)in subfile we can find out varibles and varibles
lengths in subfile record format key word.

Is This Answer Correct ?    1 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

what happens when sflsiz = sflpag? What are the advantages and disadvantages?

702


which program rpg or cl is efficent to update a transaction onto a database file and why ?

732


How can we know running job is batch or interactive?

641


What is the difference between iter and do?

661


How to handle duplicate error handling in RPG?

1664






Suppose we have one database file and it is used by 5 programs and in 3 program we have to add some records in datbase file s what is the impact on other program?

1441


what are the key words you must use when using a subfile?

680


do you use message subfiles? What are the necessary keywords required coding a message subfile?

677


How do u design a physical file, when you have 2 Unique fields like for eg in A student file student ID and student examination no both are unique

541


how do I declare a minor?

707


What is the diff bw PF/LF Name and their Record format name? what is restriction in record format then file name?

2509


what is a rpg?

690


what is data area and how it is used in rpg program ?

746


1. If there are two programs using same file and 2 users are using the file at the same time and what can be done to allow them both to access? 2. How can remove lock from the file for accessing it by both users?

474


what is the use of sflnxtchg?

793