I noticed last to last week that every third visitor to this website searches for "copybooks". I am sorry that I could not write about copybooks earlier because of extremely hectic schedule last week. If you search something related to AS400 or RPG ILE and do not find it here, Please ask your question in the forum. Someone will certainly answer your question.
Anyways, Coming to this article, we will learn here everything (Or most of them ;-) about copybooks.
Before we begin here's what I intend to write.
So, Now that you know exactly what the scope of this article is, choose the section you like to read from the links given at the bottom. If you like to begin from the beginning, well, this is the opening page of this article and it answers the first question about the copybook. Which is
What is a Copybook anyway(s?)?
Copybooks are "reusable components", rather "reusable RPG IV scripts" which have been tucked into different members of a source physical file. The main idea behind RPG Copybooks is reusability. You know about reusable components, Right? (If you forget, Do you remember the famous date format conversion program on your system which you call whenever you want to convert a date's format from *YMD to *MDY. Yes! that is a reusable component). In the same fashion as reusable components, copybooks are reusable RPGLE source codes (I do not know much about COBOL copybooks, but I know they do exist but I know RPG only...by now).
Here, Copybook comes in the picture. What you can do here is that you create a new separate source code just as any other RPG ILE program source and copy it into the source codes of Program A and Program B both! In future if you require the same source (copybook source) in some other Program C, you can easily copy it into it also.
Now you have at least some idea about copybooks. Haven't you?
Copybooks are not different things. They are just RPGLE sources copied/included in other source codes. Now let's learn how to declare them.
Recent comments
5 days 1 hour ago
5 days 2 hours ago
5 days 2 hours ago
5 days 4 hours ago
5 days 15 hours ago
5 days 17 hours ago
5 days 18 hours ago
5 days 19 hours ago
6 days 8 hours ago
6 days 18 hours ago