Can we use OVRDBF command without using of OPNQRYF ?
Or can we use OPNQRYF command without using of OVRDBF
command ?

Answer Posted / bharat

OVRDBF can be used separately without opnqryf to override
the attributes of file.
Now, OPNQRYF without ovrdbf, is also possible:
opnqryf creates the open data path and to share the same
data path in a program we use ovrdbf share(*yes), if we do
not use ovrdbf, then program will have its own ODP, so it
will read the file from begining on which query has been
run. So, OPNQRYF selected records will have no importance.
So, we need to use CPYFRMQRYF command and put the selected
recoreds in to runtime file and use that file to read in
program.

Is This Answer Correct ?    43 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

how does union file maintains record formats?

722


Can we debug the MSGW JOBS?

1015


how can database records be read without lock ?

1371


define data structure?

1186


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

1230






Difference Between Skip Before & Space Before?

763


can you specify a display file to be used in the following modes input,output, or combined modes ?

1059


What Does 'sr' In Columns 7-8 Of C Specs Mean?

1200


when do you explicitly open files and close files in an rpg program?

1376


how to validate input values in display file ?

754


What Does Lokup Does In Tables & Arrays?

837


what key word is used when screen is re-display?

735


What Is The Error If We Don't Get Login Screen?

777


difference between sflrcdnbr and sflnxtchg?

802


what if my system I runs with system value qccsid 65535?

702