Books by Bryan Meyers

Programming in RPG IV

Control Language Programming for IBM i

RPG IV Jump Start

Power Tips for RPG IV

VisualAge for RPG by Example

 
FAQs and Tips



RPG IV Style for the 21st Century Print E-mail
Written by Bryan Meyers   

I've often postulated that few computer languages are changing as fast as RPG. Although it originated more than 40 years ago, RPG has evolved from a punch card heritage to a fully featured language that drives many modern business applications, in only a little more than a decade.

But has your programming style kept pace with RPG's evolution? It was only a few short years ago when I first wrote an RPG IV style guide and, despite my attempts to update it since then, my old, comfortable approaches to style, standards, and best practices get more outdated with every new release. In this article, I revisit and revise my suggestions for writing stylish RPG IV code.

Read more ... RPG IV Style for the 21st Century
 
Analyzing ILE Programs Print E-mail
Written by Bryan Meyers   

It's no secret that the Integrated Language Environment helps us all write more modular applications. Modules and service programs make it easy to construct programs from several small, easily maintained, reusable chunks of code. We can even create programs composed of several different languages.

Although development using modular chunks is easy, there is a bit of trouble in paradise. You sometimes need to know which application programs use particular modules and service programs. This is especially true when you modify modules and service programs, because you must rebind them to your application programs for the changes to take effect. In the past, there has been no convenient way to determine the modules and service programs your applications use. But now, you can have the Anzilepgm utility do the research and present the information to you.

Read more ... Analyzing ILE Programs
 
RPG IV From A to Z Print E-mail

A comprehensive glossary of RPG IV and ILE terms

Read more ... RPG IV From A to Z
 
%LOOKUP Function with ASCEND Print E-mail

Q: I recently ran into a problem with the %LOOKUP function (both in free and in fixed format). A converted program (which had originally used the LOOKUP operation) was using %LOOKUP on an array that was set up as ASCENDING. When the lookup occurred, no element was found. When I removed the ASCENDING keyword, the lookup word fine. Any ideas?

Read more ... %LOOKUP Function with ASCEND
 
Listing Source Change Dates for ILE Programs Print E-mail

Q. We have utilities that do a DSPOBJD to an output file. We then read this output file into a query specifically looking at the source file library, source file change date, and source file change time. This works on OPM programs but I cannot seem to get the same information on ILE programs. I've tried DSPOBJD and DSPPGM. Ideally I would want this information in an output file but if I have to do *PRINT and CPYSPLF I will. Do you know of any command that offers this for me? The most I've been able to come up with is program creation date; not source file change date.

Read more ... Listing Source Change Dates for ILE Programs
 
Using %DEC to Convert Character to Numeric Print E-mail

Q. In your December 2004 article, "10 Cool Things About RPG IV," I could not get the %XLATE('$*,':' ':Amount) line to work. Testing the %XLATE with constant fields and stepping through it, I found the $ would be replaced by a space, but the asterisk and comma were left in. The only way it would work was to do three %Xlate functions - removing only one of the characters at a time. Did I do something wrong?

Read more ... Using %DEC to Convert Character to Numeric
 
Replacing *ENTRY PLIST with a Prototype Print E-mail

Q. I am trying to find the /Free replacement for the *ENTRY PLIST. The conversion tool in WDSc doesn't touch this code. Is it possible to do this in /Free code?

Read more ... Replacing *ENTRY PLIST with a Prototype
 
<< Start < Prev 1 2 3 4 5 Next > End >>

Page 1 of 5