SQLRPGLE Shorts – How to Call QCMDEXC with IBM i SQL Surely every RPG programmer is familiar with the QCMDEXC *API for exciting any IBM i Command from within any HLL (High Level Language) program. What is QCMDEXC? The Execute Command (QCMDEXC) API runs a single command. It is used to run a command from

Read More

DSPF Indicator Command Keys in AS400 RPG (… and iSeries and IBM i obviously) Ever since my days at JBA, I’ve used the old-fashioned function key indicators to handle internal Function Keys selections, or Command Keys as they were known in the System/3x days. These PFKEY ranges from keys 1 through 24. Most programmers used

Read More

Count with SQLRPGLE Variable File Name Been having fun with SQL and RPG ILE this afternoon… the question was “How do I find out if and how many policies exist in one of the reservation files for a given customer code?” Obviously, we could write a little piece of RPGLE doing a READ LOOP and

Read More

The Winner is Visual Studio Code Visual Studio Code is an IDE (Interactive Development Environment). It’s a modern coding tool helping software developers to work with many languages. To write and maintain source code on your IBM i, iSeries or AS400 system, simply download and install the ‘Code for IBM i’ addon. Visual Studio Code

Read More

Taking your Resume from simple text to Infographic As I mentioned in another blog – I use LinkedIn to edit and maintain my resume. It makes the information editing very simple and clean, and also generates a nice-looking basic resume layout. Maybe this layout works fine – but have you ever looked at infographic versions

Read More

My mate Toby sent me this email: I love RDI … But I do come across one issue that I’m sure you can sort out… using SEU if I wanted to find the start of a subroutine, I always made them # something like #Clr or #Bld etc. and there was only 1 place in

Read More

How to use ‘Conditional Selection in RPGLE and CLLE’ Way back in 2008, I wrote this blog about how to do various condition selection in RPG. So, I suppose it time to modernize those code examples in modern RPGLE Free, tidy it up, and add the same code examples in CLLE. In RPGLE (and in

Read More

What are single page subfiles? A single page subfile is a SCREEN OF DISPLAYED DATA, loaded one page at a time. The displayed data is equal to the maximum number of records that can be displayed at a time. In other words, in a single page subfile, all loaded records are displayed at a time.

Read More

Built-In Functions in RPGLE – %EOF & %FOUND %EOF(filename) This built-in function is used to detect end-of file, beginning of file, or subfile full conditions while performing a file operation. Rather than using indicators, we should use %EOF to check if the end of file is reached. %EOF returns ‘1‘ if end-of file, beginning of file,

Read More

Let’s look at a quick little example RPG email validation program – SQLRPGLE ILE There are lots of code snippets, example programs, and long waffling discussions in internet land filled with pointy-headed AS400, Series, and IBM i programmer chaps (and chappettes) arguing about the best way to “validate an email address in RPG”. I know

Read More

Do Loops in RPG Whenever I find myself editing some old RPG3 or RPG400 code, I try to spend a coffee* cleaning the code up to a more modern and readable form. * A ‘coffee’ is the amount of time it takes to drink a regular cup of brew. This is slightly shorter than the

Read More

IBM RDi Rational Developer Ports What TCPIP ports are used by IBM RD/i? I’ve been struggling to get Rational Developer working while remote during the ‘Rona. While I’m working locked in my cellar, candles flickering, dogs growling and rats a scurrying, my laptop is connected with VPN and my guess is that VPN is blocking

Read More