How I can read and display three fields in the record
format DSPFM1 of the display file,while
one field(using in one file) is NAME which is Key field in
field reference file and another two fields are AGE and ROLL
NO are using another file.

Please send me coding part.

Answer Posted / syam

I am Pasting Code.
FFILE1 IF E K DISK USROPN ->Reading pf
FDSPF CF E WORKSTN USROPN ->dspy file

C OPEN FILE1
C OPEN DSPF
C SETLL FILE1
C READ FILE1 51
C *IN51 DOWEQ *OFF
C WRITE DSPFM1
C READ FILE1 51
C ENDDO
C CLOSE FILE1
C CLOSE DSPF
C RETURN

it will show all the records from file undil file ends.
if you need ILE RPG Free fromat code pls post again your
request

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

what is the use of unique keyword and what level it is defined?

930


what is logical file?

605


different type of cursor?

640


Hi,Please give me the the answer for these quesitons? 1.what is IFS and ICF and RAPE amd DISKET fils? explain with example please? 2.What is the difference between POST AND SPACE OPCODES? 3.Can anybody tell me default printerfile command and object type?

2087


WHAT IS AS/400 SYNORIO?

2890






how will you display a particular page in subfile ?

1054


how do you read data area in an rpg program?

1116


what are necessary keywords to code message subfile?

1035


i am using non join multiple format my 3 database file is like that pf97 R REC ENAME ETENNO ESTATUS K ENAME pf98 R REC1 ENAME ESAL K ENAME PF99 R REC3 ENAME CRDCARD EID K EID & MY NON JOIN LOGICAL FILE IS ALSO SAME EXCEPT RECORD NAMES BEFORE I TRIED WITH 2 FILES SO ITS SAYS ERROR I.E.(Key field attributes must be same as for previous formats. ) SO I CHANGED KEYFIELD ACCORDING TO PF SO ITS WORKING BUT AFTER ADDING 3 FILES ITS SAYING SAME ERROR . I DONT KNOW I NEW IN AS400 PLLZ HELP ME I HAVE ONE MORE QUE. CANT BE USE DIFFERENT KEYFIELD (NOT ACCORDING TO PF) IN NON JOIN LOGICAL FILE.

1043


how do you use exceptional write in c specs?

1156


how to develop some simple graphs (bar charts) using just html?

675


what are the basic features of seu?

617


what is a join logical file?

757


how can we run a batch job?

737


how can u check no of records in a file?

682