With a little creativity, SQL allows you to add a form of overloading to RPG that can really extend your toolkit.
Written by Joe Pluta
In the previous article in this series, I created a simple user-defined function (UDF) that acted as an SQL interface to an RPG service program procedure. It was simple and easy to do, but the emphasis was on simple. The UDF simply passed parameters from the SQL environment straight through to the RPG procedure and returned the result. This is enough in many cases, but at other times, you might want a little more flexibility.
Retrieve the exact table of MI object types via the undocumented API QLICNV.
Written by Junlei Li
On IBM i, historically there are two flavors when referring to objects. At the MI level, MI objects are categorized by a 2-byte MI object type code (1-byte type code and 1-byte subtype code). At the OS level, external objects (also known as CL objects) are categorized by external symbolic type names—for example, *FILE. An external object may consist of one or more MI objects. Each MI object type also has a corresponding descriptive external object type name; for example, the external object type name of a cursor object (with MI object type hex 0D50) is *MEM (Member). As you might know, the number of MI object types changes from release to release. This makes sense for an object-based system that has been evolving continuously.