suppose there are 100 records and i want to read records between 60-70 how we can read this 10 records in rpg

Answers were Sorted based on User's Feedback



suppose there are 100 records and i want to read records between 60-70 how we can read this 10 recor..

Answer / siyan sinhag

It such a easy question. Make few way to solve. one of my way. Declare the file and do yourself coding atlast what you do,

Setll RRN REC;
Dow (n <=10);
n= n+1;
....
....
enddo;

Is This Answer Correct ?    7 Yes 2 No

suppose there are 100 records and i want to read records between 60-70 how we can read this 10 recor..

Answer / surya siram

Hi,

Declare the physical file and make sure the physical file shouldn't have any keys. Load value 60 into RRN variable and then by using SETLL RRN PF, hit the physical file. Then increment the RRN upto 70 and read the records.

Is This Answer Correct ?    4 Yes 0 No

Post New Answer

More RPG400 Interview Questions

use of PUTOVR,OVRDTA,KEEP keywords?

2 Answers   HCL,


1.what are the ARITHMETIC EXPRESSIONS IN CL PGM? 2.How to PASSING PARAMETER TO CL PGM?

1 Answers   NetCracker,


without logical file we cannot access the data in physical file.but we specify physical file in the program(ie:- Ffile IF E k disk).how can it be accessed?

3 Answers   HSBC, TCS,


How would display prime numbers using CL program?

0 Answers   Hexaware,


in which journalling which attributes are necessary

2 Answers   CTS,






HOW TO DELETE THE RECORD FROM MASTER FILE WHICH IS LINK BY ANOTHER TRASATION FILE WITH REFERTIAL INTYGRITY?

1 Answers   TCS,


what is the rpg system?

0 Answers   IBM,


what is edit word and edit code

0 Answers   Cap Gemini,


what is importance of 'MAPFLD' IN OPNQRYF FILE ?

2 Answers  


How do you find whether a record is locked or not?

2 Answers  


I have a RPG program of 100 Lines and first line is to SETON indicator LR. Will the program execute rest of the 99 Lines?

6 Answers  


how to display all the members records in a physical file without using ovrdbf?

9 Answers  


Categories