Do you know the best way to use optional parameters with procedures?
Written by Tom Snyder
When you're using procedures, you have to ability to support optional parameters by using the special keywords *NOPASS and *OMIT. This article discusses the difference between the two and the appropriate times to use them.
There are better ways for storing textual information.
Written by Bruce Vining
As a contract programmer, I have the opportunity to review quite a bit of i-based code that is to be rewritten as part of various modernization efforts. One programming style that I encounter fairly often is the use of compile-time arrays to store textual information for use on displays and reports. These companies' databases may have, for instance, an order-status field (OrdSts) with values such as P, O, C, H, I, R, and S to represent order pending, order, order canceled, order held by accounting, order held due to inventory, order released for processing, and order shipped, respectively. When returning order status information to a user, the application programs may then utilize a compile-time array, as shown below, to provide a textual description of the order status through a display or printer file character variable (Status).