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



On 8/8/2013 6:11 PM, Alan Campin wrote:
... What you want is to have something like this
encapsulated inside a procedure or maybe better yet in a procedure in a
service program. The caller should just ask what the value related with
this value. How the procedure does it should be hidden.
...
All of this points to the fact that we need better mechanisms for declaring
arrays inside procedures.


Not disagreeing with your conclusion, but if you use a procedure, you don't really need an array.

select;
when code = 'h':
return 'header';
when code = 'H';
return 'HEADER';
...
other;
signalInternalError ('Unknown code "' + code + '"');
endsl;

But aside from that, I agree that RPG is a lacking in array initialization. I don't hate CTDATA quite as much as Jon does, but almost as much. Still, I do use it sometimes if it seems less icky than other options.


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.