Let's evaluate the reasons you might want to take this approach.
Written by Tom Snyder
You've heard about embedded SQL and maybe you've tried embedded SQL, but you may be asking yourself, "Why would I use embedded SQL?" That's the course that I have taken. Of course, when a new capability comes out, I am usually eager to start digging into it and figuring out how it works. And I have done that with SQL, but I couldn't easily find a reason to justify its use until recently.
For the last few months, we've been looking at various considerations related to the running of CL commands using the QCMDEXC, QCAPCMD, and system APIs. As part of that discussion, we've explored some of the ways your RPG program can remove error-related messages from the job log. Due to several notes that I have received on the topic of message retrieval and removal, this article (and a following one) will go into more detail concerning some of the points I briefly discussed last month.