MIDRANGE dot COM Mailing List Archive



Home » MIDRANGE-L » October 2012

RE: Files declared at the procedure level



fixed

I think the following:

If the file is global, then any sub-procedure using that global
file will change the record position, just as the main
procedure would.
Simple: global = global; similar to a global field/variable

Declaring a file in a sub-procedure that is the same as defined
in the main procedure would create an additional instance
of the "path" which would be local to that sub-procedure.

In this case, you would have two, independent "paths" to
the same file.

Best to test before getting in deep.


-----Original Message-----
From: midrange-l-bounces@xxxxxxxxxxxx [mailto:midrange-l-bounces@xxxxxxxxxxxx] On Behalf Of Rpglist
Sent: Wednesday, October 03, 2012 3:54 PM
To: Midrange Systems Technical Discussion
Subject: Files declared at the procedure level

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?


--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list To post a message email: MIDRANGE-L@xxxxxxxxxxxx To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx Before posting, please take a moment to review the archives at http://archive.midrange.com/midrange-l.








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