AS400 Mid Range/rpg questions
Expert: Concise Systems/Laird Scranton - 2/27/2002
QuestionHi I am a newbie in RPG AS400 programming, all any other programming in AS400 environment for that matter.
I am just wondering exactly what RPG stands for and what is the main purpose of it. Is it to create report?
What is an indicator that can be set on and off and what is the purpose on doing that?
And the last questions is kinda dump but I just got to make sure. When you compile an RPG source code and you set "Y" to overwrite the former compiled program. WHen the message saying the job is ended abnormally does it effect the existing program or it is harmeless?
thank you
I really appreciate your time
AnswerRPG stands for Report Program Generator. Originally it was conceived of as a kind of query tool for generating reports. Over the years it has become a powerful business programming language.
In each RPG program, a programmer has 99 indicators available to use, plus several other sets of special-purpose indicators. The programmer decides to assign a meaning to an indicator - for instance, maybe indicator 21 is turned on when a date field is zero. The programmer can then condition the printing of the date on "N21", so that zero dates do not print. Another example might be when the programmer chains to a file. The CHAIN operation requires a resulting indicator in the HIGH position - the indicator is set on if the requested record was NOT found, and turns off if the record WAS found.
When you choose to overwrite the previous program on a compile statement, the program is only overwritten if the new version successfully compiles.