×
The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.
On 1/14/2019 4:46 PM, Jack Woehr wrote:
On Mon, Jan 14, 2019 at 2:36 PM Tyler, Matt <matt.tyler@xxxxxxxxxxxxxx>
wrote:
Plus, the tool I sent gives me the ability to wrap it in an external SQL
procedure. How would Python accomplish this?
If you can call a CL passing parameters, you can call Python with those
params, because you can call Python from a CL.
A little while ago, I had to plug in a Python function/process into an
existing RPG program. I'm on 7.3, and to the best of my knowledge,
Python is not a participant in the CALL/PARM family. That is, if my RPG
program were to call a CL which were to invoke a Python program, and the
Python program were to want to return a mixed case name back to the
caller, there's no mechanism to pass it back in the parameter list.
I solved it thanks to Scott Klement's insights into how pipes work
between PASE and ILE. Basically, my RPG program sets up pipes for the 3
'standard' streams, does a spawn() that invokes the Python program with
UPPER_NAME_PARM and then Python does its thing, putting lower_name_parm
on STDOUT, which the RPG program then does an fdopen() and fgets() to
retrieve. Don't forget to translate from ASCII :-)
If there's a simpler way that a CLP can get an answer back from a Python
program, I'm all ears!
As an Amazon Associate we earn from qualifying purchases.