Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

AS400 RPG Simulator

I have a urgent requirement to call an RPG Program from java. As suggested in this Accessing RPG on iSeries from Java question. I am planning to use JTOpen. But unfortunately I dont have access to any of theses systems. So is there any way I can test the java program ? Are there any RPG simulators for Windows?

Any help or ideas will be highly useful

With Regards, Srinivas

like image 545
Srinivas Avatar asked Jan 20 '10 18:01

Srinivas


People also ask

What is Rpgle AS400?

RPG is a high-level fully procedural programming language used by businesses to create commercial business applications on IBM's leading minicomputer system, the AS400 iSeries. RPG has gained wide acceptance and has evolved massively since its inception.

What is RPG free?

Free-form RPG allows code to be specified as free-form statements rather than in specific fixed columns. Free-form code is still restricted to columns 8 – 80. The /FREE and /END-FREE compiler directives are tolerated, but are no longer required for free-form.

What is Rpgle?

RPG IV, a.k.a. RPGLE) was released in 1994 as part of the V3R2 release of OS/400 (now known as IBM i). With the release of RPG IV, the RPG name was officially no longer an initialism.


3 Answers

You used to be able to get free access to an iSeries at Innovative Systems (this service has been discontinued as of March 21 2012). On their machine you can experiment with RPG.

Some other remarks,

  • You can call iSeries programs from java including RPG programs. But if you really want to interface (use parameters/arguments) you better use ILE RPG. ILE RPG supports anything you need to interact with java including the correct datatype (including pointers)
  • JTOpen is the open source class library. That one runs fine on the as400. But in the iSeries world the normal way to install this class library is as an "License Program". Don't be scared by the word License. It is just the iSeries way like apt-get on Linux. See IBM Infocenter for more information
  • At last but not least, JTOpen is a regular java class library. You can test and try that library on your local machine. Ofcourse, you can not open a iSeries data-area but you get the feel for this class library.

BTW I think you can forget about a RPG simulator for Windows. There may be some compiler may be around that I don't know of but that is not the specific thing about RPG, it is the fact that it runs on a iSeries. And unfortunately no iSeries emulator is available.

like image 135
robertnl Avatar answered Sep 28 '22 13:09

robertnl


Are there any RPG simulators for Windows?

A RPG simulator won't do you any good. What you'd need would be something like an "ILE simulator for Java". It isn't "RPG" that is being called from Java;, but rather it's an "ILE *PGM or *SRVPGM object with particular parameter-handling characteristics". (Okay, it's also possible to call OPM *PGM objects, but no need to discuss differences.)

The point is simply that a RPG simulator wouldn't be enough. You need an "environment simulator" that processes the parameter values for Java. If you actually had a "RPG simulator", it's effectively guaranteed that calls from Java (especially via JTOpen) are not going to work with anything running in it like they would through the live PCML interface. You could probably effect calls to such programs; the calls just wouldn't be coded the same way so the exercise would be pointless.

You can't worry about it if you aren't given access to an appropriate server. Just code procedures that encapsulate any remote calls and tune them to the server environment when the time comes for that.

like image 36
user2338816 Avatar answered Sep 28 '22 13:09

user2338816


there is a free AS400 server at http://pub400.com/ Hope this works!!

like image 28
Edo M Avatar answered Sep 28 '22 13:09

Edo M