|
not sure if this will work for you?
FMYFILE1 IF E K DISK
FMYFILE1TMPIF F 1024 7AIDISK extfile('SOMELIB/MYFILE1')
D MYFILE1DS E DS extname(MYFILE1)
D TEMPDS DS 1024
C read MYFILE1TMP TEMPDS
C eval MYFILE1DS = TEMPDS
C eval *inlr = *on
---------------------------------
-------Original Message-------
From: RPG programming on the AS400 / iSeries
Date: 03/23/04 13:26:24
To: rpg400-l@xxxxxxxxxxxx
Subject: opening 2 files, same name, different libraries in an RPG pgrogram
I've got a program that needs to open 2 files at the same time, same name,
different libraries.
I'd like touse an override before calling the program to point to the
proper files in the proper librarys, so I really only need to be able to
describe the same file structure twice in a program. I'd prefer not to
have to create a logical over the file with the same keys just to get a
program to compile.
I thought maybe I could use extfile() keyword, but it appears that it
doesn't use this to get the file definition, and is only used to name the
file to the 'outside world'
other than creating a dummy logical, (or an empty copy of the original),
how can I do this with minimal muss and fuss?
thanks,
Rick
_______________________________________________
This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing list
To post a message email: RPG400-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/rpg400-l.
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2025 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.