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



Jerry,

The key to WHSHDR is 10 long.
File LIMIT20 has a record length of 20 (which needs to be twice the length of the key.)

Let's say I wanted to process 3 ranges of records: Invoice # 2000-2111, 2500-2699, 3001-3001. File LIMIT20 would contain records like this:
00000020000000002111
00000025000000002699
00000030010000003001


FINVHDR IP E L K DISK
FLIMIT20 IR F 20 10 DISK RAFDATA(INVHDR)

RPG automatically takes care of positioning the file cursor and bringing in only the proper records.

Imagine dynamically building an SQL (or OPNQRYF) statement with a theoretically unlimited number of range selections!

-mark


At 5/1/09 11:43 AM, you wrote:
Mark,

Apparently I missed that part of the discussion. Still, the concept of a "limits" file does not ring a bell. Would it be possible to put up a few lines of code (F-spec and whatever, and a few lines of Calcs) to jog or enlighten my thinking.

Thanks.

Jerry C. Adams
IBM System i Programmer/Analyst
--
B&W Wholesale
office: 615-995-7024
email: jerry@xxxxxxxxxxxxxxx


-----Original Message-----
From: rpg400-l-bounces@xxxxxxxxxxxx [mailto:rpg400-l-bounces@xxxxxxxxxxxx] On Behalf Of M. Lazarus
Sent: Friday, May 01, 2009 9:30 AM
To: RPG programming on the IBM i / System i
Subject: RE: Update primary filre

Jerry,

As mentioned earlier, this request is NOT referring a record
address file, as would be typically generated by FMTDTA (or by
#GSORT). Rather it's referring to a technique where you can specify
one or more ranges of keys to process via a "limits" file.

This has nothing to do with conserving disk space. Other methods
require a lot more code and end up being quite messy when dealing
with many ranges of records to select.

-mark


At 5/1/09 08:15 AM, you wrote:
>As someone else said, if we each had $100 to spend on RPG
>enhancements, this would not garner $1.
>
>Old programs that use RAF still work. If anyone is creating new
>programs with RAF, they need to move into the 21st century.
>
>I loved and used RAF's on the /36 because we were limited by disk
>space. Today there are more viable options (LF's and SQL DDM just
>to name two).
>
>Jerry C. Adams
>IBM System i Programmer/Analyst
>--
>B&W Wholesale
>office: 615-995-7024
>email: jerry@xxxxxxxxxxxxxxx
>
>
>-----Original Message-----
>From: rpg400-l-bounces@xxxxxxxxxxxx
>[mailto:rpg400-l-bounces@xxxxxxxxxxxx] On Behalf Of M. Lazarus
>Sent: Thursday, April 30, 2009 8:38 PM
>To: RPG programming on the IBM i / System i
>Subject: Re: Update primary filre
>
>Barbara,
>
> That means that it's more difficult to generate the limits file and
>the key lengths need to be hardcoded in the program(s) using it.
>
> Is there any technical barrier to implementing it "properly"?
>
> -mark
>
>
>At 4/30/09 09:21 PM, you wrote:
> >Jeff Young wrote:
> > > ... A Limits file was a file that had a record length of exactly
> > > twice the length of the key of the file to be processed. This file
> > > contained a From and To key to be processed. The data in this file
> > > would be used by the system to read all records in the group
> > > represented by the From and To keys. AFIK, this method of processing
> > > is only valid for program defined files.
> > >
> >
> >The file to be processed can be an externally-described file (both RPG
> >III and RPG IV). The limits file does have to be program defined.
>
>--
>This is the RPG programming on the IBM i / System i (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 IBM i / System i (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 IBM i / System i (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 IBM i / System i (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 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.