MIDRANGE dot COM Mailing List Archive



Home » MIDRANGE-L » October 2012

Re: Files declared at the procedure level



fixed

On 2012/10/3 5:54 PM, Rpglist wrote:
If I have the same file declared as a global are they both using
different file paths? What I mean is can I position the global file
at say record 10 which has an I'd of say 100 and use the procedure
to Loop through the same file without changing the record position at
the global level?


What Gary said is correct.

From RPG's point of view, the files are completely independent. The only way they would be using the same file path is if you had a share(*yes) override.

Coding a file local to a procedure behaves exactly the same as coding it in another module or another program, at least regarding the file paths.






Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2014 by MIDRANGE dot 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 here. If you have questions about this, please contact