Free Form RPG ILE Logic Example I was recording a screencast about modernizing some old RPG400 to ILE RPG this morning and had to knock up this little code example showing the difference between legacy RPG400 code and modern RPG ILE code. Note, this is not an example of good code (it’s crappy old RPG

Read More

Going the (Levenshtein) Distance Over on the RPG Cafe website, a nice chap called Smit Dixit published a sample of his RPGLE code calculating the Levenshtein distance between two words. What is the Levenshtein Distance? The Levenshtein distance is a string metric for measuring difference between two sequences. Informally, the Levenshtein distance between two words

Read More

Upgraded our IBM i systems to IBM i V7.3 yesterday and so far everything is running nicely except for this one weird little glitch: some of the existing DDS WINDOW SCREENS are bombing with CPF4169 The device file does not contain an entry for screen size when they seem to have been quietly working for years,

Read More

If there was a quick and easy solution to “how to quickly become a productive RPG IV and ILE programmer” then all of us old AS400, iSeries and IBM I developers would have gobbled up that solution in double quick time. But Wait. There might just be Ne. Drinking Tea. If you have read any

Read More

RPG CODE EXAMPLE – “Write to joblog” in Free Format RPGLE Write to the IBM i joblog is a neat way of recording details of any running jobs information. This example lets us send messages from inside a running RPG program. It’s simple using one of IBM’s API’s – QMHSNDPM – and this source code

Read More

RPG CODE EXAMPLE – “Write to joblog” in RPG with Qp0zLprintf Write to joblog lets us send messages from inside a running RPG program. It’s simple using one of IBM’s API’s – Qp0zLprintf Qp0zLprintf() — Print Formatted Job Log DataThe Qp0zLprintf () function prints user data specified by format-string as an information message type to the

Read More

Modern ILE RPG now (finally) supports “fully free form” RPG Source code This means, we can write RPG code from column 1 to the end of the line — just like other languages. No more jumping to character 10 to get passed the old reserved (H,F,D,I,C,O) specification column. You must code **FREE in column 1

Read More

Since the introduction of the latest Service Pack for IBM i V7 — cunningly entitled ‘Technology Release 7.1 — RPG programmers can now finally eschew the old fixed column coding and roam around a modern free format language. RPG is free. Finally. Lovely jubbly. Long overdue and in the words of Jon Paris (RPG Guru

Read More

RPG Programming Standards? “RPG Programming Standards” have been debated since the invention of the wheel. With an entire generation of RPG programmers evolving from the early days of System/3x column based RPG code to modern free flowing web format code the adoption of a simple clean programming layout standard has been a mythical quest. Old

Read More