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



James H H Lampert wrote:

It is IMPOSSIBLE to avoid The Cycle in RPG without going 
out of your way to do so. Maybe not very far out of your 
way, but you still have to do SOMETHING. There is not so 
much as a single non-cycle RPG program in existence that 
does not either use a RETURN statement (or RETRN for OPM), 
or at some point explicitly set the LR indicator to the 
"on" state, in order to keep The Cycle from iterating.

I stand by the main thrust of my argument: if you're not 
using either The Cycle, or the close integration between 
RPG and display files, or the ability to call external 
programs not known at compile time, then you should 
probably consider a language other than RPG. Conversely, 
if you're writing non-Cycle RPG programs that either walk 
through an entire file, or continue doing some action 
until they're told to stop, then you've probably got at 
least one more nesting level than your program truly 
needs.


So if you can't avoid the using cycle and the use of the cycle is one of
your qualifying tenants for RPG, then you are really just advocating RPG :-)

There will probably always be a few purists (historians) suggesting that
RPG is about the cycle, indicators and fixed form specifications.  Most
of the RPG programmers I've worked with either don't know it or don't
use the cycle any more.  It's a trivia topic.  I'll maintain it, but
wouldn't write any new code with it.


To your points about choosing RPG as a language..

1) RPG's "close integration" with display files ?
Are you referring to indicators ?  Maybe over CL which can't do subfiles.

2) Calling external programs "not known at compile time"
Which language can't do this ?

3) Adding an extra nesting level is usually trivial to code and
maintain.  Changing a program to use or not use the cycle is more work.



I would suggest that RPG is a good choice for business logic
programming.  It also does reports very well.


Keith

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.