× 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.



If the EXTMBR does not allow a variable then you are right, it is not 
going to work for your situation.

Sorry - I was basing my suggestion on the previous post, which I thought 
said that you could use a variable.  My mistake ... I should have looked 
at the documentation to double check.  I thought that sounded to good to 
be true ....

Adam

rpg400-l-bounces@xxxxxxxxxxxx wrote on 26/05/2006 11:06:01 AM:

> There are a few lines per member, a few comments w/in that. How I will
> know which are comments or not is  a sep. issue but it should be OK, 
there
> seems to be some blank lines in there to indicate.
> 
> THe Extmbr does not allow a variable. I am still not getting this.
> 
> > Someone suggested a keyword for the F-Spec that lets you 
programatically
> > change which member you are reading (at least that is how I 
interpreted
> > the post).  Then you don't even need a second program.  Sounds like a 
much
> > simpler solution to me ... no need to worry about using the same file 
in
> > two programs in one job stream, all logic is nicely together in one 
place.
> >
> > I think the keyword was EXTMBR.
> >
> > Adam
> >
> >
> >
> >
> >
> > steema@xxxxxxxxxxxxx
> > Sent by: rpg400-l-bounces@xxxxxxxxxxxx
> > 26/05/2006 09:49 AM
> > Please respond to
> > RPG programming on the AS400 / iSeries <rpg400-l@xxxxxxxxxxxx>
> >
> >
> > To
> > "RPG programming on the AS400 / iSeries" <rpg400-l@xxxxxxxxxxxx>
> > cc
> >
> > Subject
> > RE: Reading a member file
> >
> >
> >
> >
> >
> >
> > Yes but, there are many years of data in this file.
> >
> > It is a REPAIRS file, that has the comments they want to see in the
> > report.
> >
> > THe invoice number, is the member name. ( it is a rather old piece of
> > work, from Sys38 days, infact the file is PF38).
> >
> > SO I plan on doing a call to a second program passing the invoice 
number
> > to the CL, doing an OVRDBF w/ this file and invoice/member-name.
> >
> > Read that member, get the commments.
> >
> > Then I can pass the comments back, or perhaps update the file right 
there
> > in the second program, if I close the file first?
> >
> >
> >
> >> Simple solution there Steema... Thanks...
> >>
> >> "The more you know"
> >>
> >> Michael Schutte
> >>
> >>
> >>
> >>
> >>              "Bob Cozzi"
> >>              <cozzi@xxxxxxxxx>
> >>              Sent by: To
> >>              rpg400-l-bounces@         "'RPG programming on the AS400 
/
> >>              midrange.com              iSeries'" 
<rpg400-l@xxxxxxxxxxxx>
> >> cc
> >>
> >>              05/26/2006 09:00 Subject
> >>              AM                        RE: Reading a member file
> >>
> >>
> >>              Please respond to
> >>               RPG programming
> >>               on the AS400 /
> >>                   iSeries
> >>              <rpg400-l@midrang
> >>                   e.com>
> >>
> >>
> >>
> >>
> >>
> >>
> >> You don't need to create a list of member names to process all the
> > members
> >> in a
> >> file.
> >>
> >> Simply override the file to MBR(*ALL) and then call the program as
> > usual.
> >> When
> >> you read the file you will read records from the first member in the
> > file.
> >> When
> >> you hit the last record in that first member, and then do a 
subsequent
> >> READ, the
> >> system does a sort of mini-close/open of the file; opening the next
> >> member.
> >>
> >> This "just happens" you don't have to create the member list.  The 
INFDS
> >> for the
> >> file contains the "current" member name as you read through the 
file's
> >> records.
> >> So you always know what member you are processing.
> >>
> >> -Bob Cozzi
> >> www.RPGxTools.com
> >> RPG xTools - Enjoy programming again.
> >>
> >>
> >> -----Original Message-----
> >> From: rpg400-l-bounces@xxxxxxxxxxxx
> > [mailto:rpg400-l-bounces@xxxxxxxxxxxx]
> >> On
> >> Behalf Of Michael_Schutte@xxxxxxxxxxxx
> >> Sent: Friday, May 26, 2006 7:41 AM
> >> To: RPG programming on the AS400 / iSeries
> >> Subject: Re: Reading a member file
> >>
> >> Here's what I would do...  Either use the API that the other person
> >> suggested (I'll have to keep that in mind the next time, that one is 
new
> >> to
> >> me), or the CL command that I suggested.
> >>
> >> If you use the CL command, first execute the CL command to build the
> > file
> >> in QTEMP...
> >>
> >> Then in the RPG program do...
> >>
> >> FDSPFD     IF   E           K DISK    ExtFile(QTEMP/DSPFD)
> >>  * I'm doing this from memory, so I don't know if you can
> >>  * reference a field from DSPFD file. You may need to Change
> >> FMYFILE    IF   E           K DISK    ExtMbr(MBNAME) UsrOpn
> >>
> >>  /Free
> >>
> >>    Read DSPFD;
> >>    DoW not %EoF(DSPFD);
> >>
> >>        // Close MyFile In Case It's Open
> >>        If %Open(MyFile);
> >>           Close MyFile;
> >>        EndIf;
> >>
> >>        // Open MyFile To The Member
> >>        // Specified In field MBNAME
> >>        Open MyFile;
> >>
> >>        Read MyFile;
> >>        DoW not %EoF(MyFile);
> >>
> >>            // Do MyFile Processing... Writing To Workfile
> >>            Read MyFile;
> >>        EndDo;
> >>
> >>        Read DSPFD;
> >>    EndDo;
> >>
> >>    // Close MyFile In Case It's Open
> >>    If %Open(MyFile);
> >>       Close MyFile;
> >>    EndIf;
> >>
> >>    *InLr = *On;
> >>    Return;
> >>
> >>  /End-Free
> >>
> >>
> >>
> >> Michael Schutte
> >>
> >>
> >>
> >>
> >>              steema@diskhaven.
> >>              com
> >>              Sent by: To
> >>              rpg400-l-bounces@         "RPG programming on the AS400 
/
> >>              midrange.com              iSeries" 
<rpg400-l@xxxxxxxxxxxx>
> >> cc
> >>
> >>              05/25/2006 05:38 Subject
> >>              PM                        Re: Reading a member file
> >>
> >>
> >>              Please respond to
> >>               RPG programming
> >>               on the AS400 /
> >>                   iSeries
> >>              <rpg400-l@midrang
> >>                   e.com>
> >>
> >>
> >>
> >>
> >>
> >>
> >> I think what I can do is to read the entire file, and make a work 
file
> > out
> >> of it.
> >> I only need to be concerned w/ the past 2 years.
> >>
> >> Is the approach the same in this scenario, of reading the file, all 
of
> > the
> >> members? U would have to make it a called program w/ the ovrdbf?
> >>
> >>> I don't know if you got the answer you wanted, but one suggestion 
that
> >>> comes to mind.
> >>>
> >>> DSPFD FILE(LIBRARY/FILE) TYPE(*MBR) OUTPUT(*OUTFILE) FILEATR(*ALL)
> >> OUTFILE
> >>> (QTEMP/DSPFD)
> >>>
> >>> Then you can read through QTEMP/DSPFD looking at the field... MBNAME
> >>>
> >>> Hope that helps.
> >>>
> >>>
> >>> Michael Schutte
> >>>
> >>>
> >>>
> >>>
> >>>              steema@diskhaven.
> >>>              com
> >>>              Sent by:
> >> To
> >>>              rpg400-l-bounces@         rpg400-l@xxxxxxxxxxxx
> >>>              midrange.com
> >> cc
> >>>
> >>>
> >> Subject
> >>>              05/25/2006 11:47          Reading a member file
> >>>              AM
> >>>
> >>>
> >>>              Please respond to
> >>>               RPG programming
> >>>               on the AS400 /
> >>>                   iSeries
> >>>              <rpg400-l@midrang
> >>>                   e.com>
> >>>
> >>>
> >>>
> >>>
> >>>
> >>>
> >>> HI - also they now want to add a comment to the report. Doesn't have 
to
> >> be
> >>> on the subfile. THe comment is stored on a file by member. THe name 
of
> >> the
> >>> member is the invoice number. That is fine I have that. My question 
is
> >> how
> >>> to read this file, by setll, or can chain, or some other way?
> >>>
> >>> Thanks,
> >>> Steve
> >>> --
> >>> 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.
> >>>
> >>>
> >>>
> >>> --
> >>> 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.
> >>>
> >>>
> >>
> >> --
> >> 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.
> >>
> >>
> >>
> >> --
> >> 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.
> >>
> >>
> >> --
> >> 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.
> >>
> >>
> >>
> >> --
> >> 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.
> >>
> >>
> >
> > --
> > 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.
> >
> >
> >
> > 
> 
#####################################################################################
> > Attention:
> > The above message and/or attachment(s) is private and confidential and 
is
> > intended
> > only for the people for which it is addressed. If you are not named in 
the
> > address
> > fields, ignore the contents and delete all the material. Thank you. 
Have a
> > nice day.
> >
> > For more information on email virus scanning, security and content
> > management, please contact administrator@xxxxxxxxxxxx
> > 
> 
#####################################################################################
> > --
> > 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.
> >
> >
> 
> -- 
> 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.
> 

#####################################################################################
Attention:
The above message and/or attachment(s) is private and confidential and is 
intended 
only for the people for which it is addressed. If you are not named in the 
address 
fields, ignore the contents and delete all the material. Thank you. Have a nice 
day.

For more information on email virus scanning, security and content
management, please contact administrator@xxxxxxxxxxxx
#####################################################################################

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
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.