× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



What is the value of the variable &TRNFILE. You can't use that name in your RPG. Normally your RPG would have to have been compiled over an existing file, whose name you know.

This dependence on *LAST member concerns me - I don't think you can rely on the order - you are better off generating a unique name, storing it in a data area, e.g., and using that everywhere. Or go to a single member with a key field (generated unique ID).

But maybe you have no choice in the matter.

I highly recommend that you read the relevant manuals.
-- "File Management" <http://publib.boulder.ibm.com/iseries/v5r1/ic2924/info/dm/rbal3mst.pdf> has all you'd want to about overrides and copying files,as well as some extra information about OPNQRYF.
-- "Database Programming" <http://publib.boulder.ibm.com/iseries/v5r1/ic2924/info/dbp/rbafomst.pdf> has details on using OPNQRYF, and other things.

HTH

Vern

At 11:42 AM 1/13/03 +0530, you wrote:
hAI ALL,
IAM USING the following  OVERRIDES IN MY CL PROGRAM....
pgm
dcl
dcl
/* override the input file  */
             OVRDBF     FILE(&TRNFILE) TOFILE(NFHPGMR/&TRNFILE) +
                          MBR(*LAST)
/* override the Procdate file  */
             OVRDBF     FILE(DASYSM001) TOFILE(NFHPGMR/DASYSM001) +
                          MBR(*LAST)

SOME CODE IN between


  /* OVERRIDE THE HEADER PURGE FILE */
              OVRDBF     FILE(DAHDRT001) TOFILE(NFHPGMR/DAHDRT001)
                           MBR(*LAST) SHARE(*YES)
              OPNQRYF    FILE((NFHPGMR/DAHDRT001 *LAST)) +
                           KEYFLD((DAHDRFCD *ASCEND) (DAHDRGRF +
                           *ASCEND) (DAHDRHFL *ASCEND))
              CALL       PGM(NFHPGMR/DAD0070) PARM(&RTCODE)
              CLOF       OPNID(DAHDRT001)
              DLTOVR     FILE(*ALL)

endpgm

will one override nullify other override ,can u just suggest me whether what
i ve written for requirment if right or nt? Iam going to use &trnfile and
dasysm001 in my rpg DAD0070 along with DAHDRT001...
will this logic of overriding this many files is right
?






As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.