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



Jonathan,

Try 'guarding' your secondary file reads with an IF statement instead of using arrays/tables/indexes. With the '80/20 rule' there is a good chance you've already got the secondary file record and donât have to look it up again. A four hour run on a monthly telecom billing program was cut in half to two hours with just if statements guarding secondary file reads.

Alternatively try using SQL and let SQL determine how to access the secondary files. I just recently tested a SQL statement that duplicated an RPG program with one primary and two secondary files. The RPG program took twelve minutes and the SQL took two.

Paul Morgan

Principal Programmer Analyst
IS Supply Chain/Replenishment
508-253-3934


-----Original Message-----
From: rpg400-l-bounces@xxxxxxxxxxxx [mailto:rpg400-l-bounces@xxxxxxxxxxxx] On Behalf Of Jonathan Mason
Sent: Wednesday, August 04, 2010 6:36 AM
To: rpg400-l@xxxxxxxxxxxx
Subject: Arrays and Performance

We have a number of programs, some in RPG/400 and others in RPG IV, that
load reference data from various files into arrays in an attempt to
reduce the performance impact of multiple chains to database files.

...

Does anybody have any knowledge of the performance benefits and pitfalls
of any of these approaches? What do others do when faced with the same
problem?

Thanks


Jonathan Mason

As an Amazon Associate we earn from qualifying purchases.

This thread ...

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.