T.Snyder
These examples are provided as educational code segments. It is actually common practice for generic service program arguments to be defined in a way to explore the limits and encourage flexibility. Simplicity is also another factor in providing code samples that target an objective in learning which would also be illustrated by the lack of exception handling to keep the sample code as minimal as possible to focus on the objective. I am unsure if you have ever read the ILE RPG Programmer\'s Guide provided by IBM. But, there are several such examples provided in that publication that use these parameter definitions and I was extremely happy to actually see that there is an example of a procedure in the programmer\'s guide that performs a less flexible version of this tip with a procedure called "cvtToAscii" using the QDCXLATE API with the exact same parameters as defined in this code sample. So, I would think that if IBM was demonstrating code functionality with the same exact definitions, then it should be an adequate solution. But, there is always the balance of simplicity, performance and flexibility. So, depending upon the situation there could be different solutions.
Please login to make comments.
User Rating: / 6
PoorBest 
   MC-STORE.COM