Which is better LF or OPNQRYF ? When should we use LF and
when should we use OPNQRYF ?

Answer Posted / adarsh

It depends on the frequency of accessing the records from
physical file. If records are huge and frequency of
accessing them is high then go for LF , but if records are
huge or less but Frequency is minimal then go for QPNQRYF
as it does not create a permanent object.

Is This Answer Correct ?    3 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

what are the uses of factor1, factor2 and result field for the rpg operation code parm?

578


define the rcvf command?

978


what does the opcode free do?

1115


To Add A File To The 'file Selection' Option Of A Query, The Function Key To Be Pressed Is?

787


how can you detect overflow for a print program that prints multiple lines per cycle?

950






how can I automatically refresh a web page?

628


when would you use or not use this approach?

886


what is the version of os/400 that we have?

946


define what a data area is along with a brief example of what it may be used for?

953


how will you display a particular page in subfile ?

1044


what is the maximum number of fields under a record format of physical file?

991


1. There is a file called Month. Month has 12 members called Jan, Feb, ..., Dec. How to design a rpg code which can access any member and show its content. (User can ask for any member when required)?

403


how to toggle between single line and multi - line display of a particular record in a subfile?

1076


How to reverse the string in rpg

1198


difference between view and index ?

700