how to learn RPG/400

2020-06-20 04:44发布

I heard about RPG programming from my lecturer. I would like to give it a try. The problem with it is that, how I do the programming? I don't know the OS and the IDE to suit the needs. Any help?

3条回答
劫难
2楼-- · 2020-06-20 05:20

Thank you for your interest in RPG. RPG runs on an IBM i (aka AS/400, iSeries, Systemi) system. This is not a server you can easily buy on your own. The starting price is around $15,000 on up to millions. However, you can pay for access to a system or can try out the system using a free host. Check out http://www.holgerscherer.de/ for a free account. (Thanks @kratenko)

Take a look at midrange.com which is a bunch of mailing lists related to the platform. Also look at their wiki which is a decent staring point for at least seeing what the system is about. (Note: I am a moderator for the Midrange.Com's .NET mailing list).

查看更多
爱情/是我丢掉的垃圾
3楼-- · 2020-06-20 05:34

Check out http://pub400.com/ (used to be at http://www.holgerscherer.de/ -- it changed in 2017) -- you can actually get a free account on an AS/400 (aka sytem i) and start some programming in RPG there. But you'll be stuck with Version V5R4 there (they have more recent ones, but not for free...) and some of the features that let you program RPG in a way it starts making fun where introduced in V6R1. On the other hand: if you'll ever have to work with people who have been programming RPG for quite some time, it's possible you wont ever see any of that features used anyway, so V6R1 would give you a wrong impression...

Don't get me wrong, it is possible to write useful (and maybe even structured) programs in RPG, even pre-V6R1. But there are RPG-Programmers out there that refuse to use such unuseful modern features as procedures, and they prefer to use hundreds of global variables with tons of side effect, where every variable has two or three different names. Don't follow that path. Just two tips for you, as reading other people's code could possibly lead you in the wrong direction:

  1. The concept of procedures has been integrated into RPG years ago. I don't see any reason for using subroutines nowadays, but you will see them. Still you needn't use them in your code.
  2. Datastructures can be declared as qualified. Always do that! Never use unqualified datestructures. You can even pass them to procedures as parameters.

If you ever have a really nasty problem, just google until you find an answer by Scott Klement. Normally there always is a solution to your problem allready posted by him...

查看更多
贪生不怕死
4楼-- · 2020-06-20 05:38

Ask your teacher about access to the IBM i at your school. If there isn't one, your options are limited. There are several time sharing services available; search for "iseries timeshare". You'll need a TN5250 emulator to access the machine. To the best of my knowledge, there are no RPG compilers / runtime environments that will work on a PC.

As far as the IDE, the machine has a native application (green screen) called PDM which uses an editor called SEU. I use a graphical IDE based on Eclipse called WDSC. This has been superceded by a new, for-fee, product called Rational Developer for Power Systems.

I second Mike Wills' answer to check out the forums at midrange.com.

One final thing. RPG/400 is obsolete. There haven't been any changes to RPG/400 is a long, long time - like a decade. The current version of RPG is ILE RPG, often called RPG IV. The reference manuals for the system are at http://publib.boulder.ibm.com/eserver/ibmi.html If you don't know what version, choose V5R4. Click the top link on the left panel, then Programming, then Languages.

查看更多
登录 后发表回答