Have you ever mentioned RPG to a teenager? He probably asked you about role playing games rather than Report Program...
By submitting your email address, you agree to receive emails regarding relevant topic offers from TechTarget and its partners. You can withdraw your consent at any time. Contact TechTarget at 275 Grove Street, Newton, MA.
Generator (RPG), the programming language of choice for most AS/400 and iSeries 400 users.
Despite its acronym being co-opted by frivolity, RPG is still the language of choice for AS/400 programmers, according to a recent search400 poll. Almost 90% of the 862 respondents said they thought RPG was going to be around for a while. This is probably not surprising to many within the AS/400 industry.
But the more important question is why is RPG still relevant? Is there so much code written in RPG that companies don't want to go to the expense to change it? Do programmers not want to learn new skills and waste the time they spent learning RPG? Or, is it simply the best language for iSeries programming?
Even RPG's detractors would find it difficult to deny its pervasiveness. With over two decades of use, moving away from RPG would be difficult, as all the programs would need to be re-written. Some say, in a historical sense, it's second only to Cobol in popularity.
RPG and the AS/400 platform have a long history. When the System/3 was introduced in the late 1970s, RPG II was released. A few years later, RPG III was released with the System/38, which included the ability to work with a fully integrated database, according to the AS/400 Primer by Ernie Malaga, Doug Pence and Ron Hawkins. In 1994, RPG IV was released. RPG V is currently being developed.
For Bob Kosharek, RPG goes hand and hand with the reliability of the AS/400 platform. "The AS/400 is a great platform. The operating system is fantastic. The database is a great and RPG makes for a perfect fit," said Kosharek, a senior developer at Everbrite of Greenfield, Wis.
Others agree with Kosharek. Another Search400 poll found 45% of respondents believe the best language for writing apps on the iSeries is RPG. By contrast, 37% said they had too much RPG code to switch. Just 13% said they had too much invested in RPG skills to switch to the new "hot" language.
Is Java your cup of tea?
Java is the latest language to come along that has challenged RPG on the iSeries. Few would completely deny Java on the platform has merit (a few high-ranking benchmarks can attest to that.) However, RPG isn't going anywhere soon, programmers contend.
"I don't feel companies are feeling as much pressure today, certainly not as much as a year ago. The hype train is slowing and people are realizing that it pays to stick with a winner," said Brad Stone, a programmer and consultant from southern Minnesota. "There's no reason to totally rewrite your applications in any language."
Pascal Jacquemain, a midrange professional from England, said companies need to walk a fine line between keeping their RPG up-to-date while exploring new technologies.
"We are now told, even by IBM, that the language to go for is Java," Jacquemain said. XML and other business-to-business (B2B) utilities are probably more important to learn, he said. The bottom line is "the iSeries is much more than an RPG machine, and its programmers should also be much more than just users of RPG."
Kosharek studied Cobol but he found it requires much more typing especially compared to how "simple and straightforward" RPG is. He had to learn Java 18 months ago because his company got an Ethernet but found the language "convoluted and confusing."
RPG is not for role playing games, but it makes for good business apps
RPG is not good for making graphic intensive video games (at least yet). The language has a long history of making business applications, which where most say it belongs.
Both RPG III and the newer RPG IV are "good enough" for general purpose business applications such as invoicing programs, order entry programs and other applications that require aggressive database access, said Bob Cozzi, who has written several books on RPG. RPG, however, is not well suited for creating compilers or word processing programs or spreadsheet programs, he said.
Cozzi sees a larger problem beyond RPG, namely "DDS." It is the language that is used to describe those "old fashion" green screen applications. "Most people attribute the green screens to RPG, but that couldn't be further from the problem," he said.
"However, if I were to switch to something else, such as C or C++, I am still limited to green screens in those languages since there is no native AS/400 graphical user interface that IBM supports," Cozzi continued.
Stone likened using other, more scientific, languages for business programming to "using an air hammer to install cedar shingles." Using Java to write a simple reporting application would be overkill.
"RPG is a business language, developed with the business programmer in mind. This includes Web applications. You just can't beat the native (database) access, speed and predictability of RPG for your business applications."
"RPG is a great solution for Web applications because you have everything you need right there on the machine. No need to go through clunky installs of ancillary software to make it work," said Stone, who dubbed his approach "eRPG" and wrote a book about it. "The speed of native RPG web applications also is one to be rivaled. And, if you combine the time for server setup, configuration, and application development RPG is unmatched."
Now, Stone says there is nothing special about eRPG, it's just "straight, old RPG." The one drawback to using RPG for Web applications is that you can't do Java applets but you can't use them with most CGI programming languages anyway, Stone said. RPG would be great for writing an application allowing someone to check the status of an order online with a Web browser, he said.
For more information:
Let us know what you think about the story, e-mail Edward Hurley, assistant news editor