Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


what is the necessary command needed before OPNQRYF and why?

Answers were Sorted based on User's Feedback



what is the necessary command needed before OPNQRYF and why?..

Answer / abhishek bajpai

It is not mandatory to use OVRDBF(*Yes) before OPNQRYF. You
can still use OPNQRYF without OVRDBF.
But here the pupose of the OPNQRYF won't be solved.
Opnqryf creates its own 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
records in to runtime file and use that file to read in
program.

Is This Answer Correct ?    20 Yes 2 No

what is the necessary command needed before OPNQRYF and why?..

Answer / kcsyam

OVRDBF with SHARE(*Yes) share the access path

Is This Answer Correct ?    17 Yes 3 No

what is the necessary command needed before OPNQRYF and why?..

Answer / sumit gupta

Hi guddu............
OVRDBF is not mandatory before doing OPNQRYF. OVRDBF is
only used to share the open data path within the calling
program(i.e we can use the selected records from OPNQRYF in
further program whose call is being made after
OVRDBF+OPNQRYF).

But is we dont use the OVRDBF command then open data path
will not be shared and if we done the RCVF on that file
after OPNQRYF(WITHOUT OVRDBF) then the selected records
from OPNQRYF will not be used and this RCVF will process
all the records from that file.

OVRDBF command is used just to share the open data path (By
specifying SHARE(*YES).
We we want to use the selected records from the OPNQRYF in
our further programs which call after this CL then we can
use CPYFRMQRYF command to copy all the selected records
from this OPNQRYF and then RCVF on this new file(which has
got generated by CPYFRMQRYF).

Is This Answer Correct ?    11 Yes 2 No

what is the necessary command needed before OPNQRYF and why?..

Answer / surendra y mudliar

OVRDBF command

Is This Answer Correct ?    5 Yes 2 No

what is the necessary command needed before OPNQRYF and why?..

Answer / guddu

Can any one explain Why OVRDBF is mandatory? with out that
cant we execute OPNQRYF?

Is This Answer Correct ?    2 Yes 1 No

Post New Answer

More RPG400 Interview Questions

Suppose my file has 10 fields and I want to make the 2nd field zeros in all records. And assume I have millions of records and I dont want to read each record and update the desired field with 0. Any other way to do this in one step operation?

1 Answers  


Suppose i am having 3 programs PgmA,pgmB,pgmC and using source debugger. At debugging time i found that pgmC having some code error..then in debug mode directly how can i debug pgmC

2 Answers  


How can we access Interactive job LDA in Batch Job?. and How we can access a file in interactive QTEMP lib in Batch job?.

4 Answers   IBM,


how to run only 10 modules of existing N modules in service program in RPGILE ?

3 Answers   Wipro,


In case if I want to know whether a record exists in a file, which one do you prefer CHAIN or a SETLL and why ?

1 Answers  


what is the difference between SETON RT & RETURN?

5 Answers  


How we will read call stack?

4 Answers  


thanks mr.Harshad R Suryawaunshi,i'm new to as400 i think you are telling in rpgile i know only rpg400 if possible can you tell in rpg400

0 Answers   iGate,


wat is the difference between dataarea and data queue?

5 Answers   Airtel, Four soft, Shahi Exports,


Can someone tell me tell me what is meant by message wait...?

1 Answers  


Why there is invention of RPG if we can do insert update delete in CL through SQL.Why the rise of RPG?

1 Answers   Infogain,


What is the difference between iter and do?

0 Answers  


Categories