Difference between revisions of "Category:RPG"
Line 1: | Line 1: | ||
== Program Status Data Structure == | == Program Status Data Structure == | ||
− | This structure contains | + | This structure contains subfields that hold a lot of information about the current program and the job it's running in. It provides the easiest way to get the program name, the job name, user ID, exception information and more. |
You declare it in the data definition section of the program like this: | You declare it in the data definition section of the program like this: | ||
Line 14: | Line 14: | ||
D PSDS ESDS | D PSDS ESDS | ||
− | Place the data structure template file in the library list during the compile. Create the template file by compiling PSDS from the [ftp://ftp.pbhall.us/pub/psds.txt source] as a normal data file with no members. | + | Place the data structure template file in the library list during the compile. Create the template file by compiling PSDS from the [ftp://ftp.pbhall.us/pub/psds.txt source] as a normal data file with no members. Use the subfields as you would any other variable in your program. |
Revision as of 05:14, 3 April 2005
Program Status Data Structure
This structure contains subfields that hold a lot of information about the current program and the job it's running in. It provides the easiest way to get the program name, the job name, user ID, exception information and more.
You declare it in the data definition section of the program like this:
* Program Status Data Structure D SDS
List the sub-fields you need below that. They're described in the ILE RPG language reference.
Declaring an externally described data structure allows you to use any of the information in the program status data structure without worrying about sub-field locations. You just add a declaration like this to your program:
* Program Status Data Structure D PSDS ESDS
Place the data structure template file in the library list during the compile. Create the template file by compiling PSDS from the source as a normal data file with no members. Use the subfields as you would any other variable in your program.
Subcategories
This category has the following 2 subcategories, out of 2 total.
Pages in category "RPG"
The following 33 pages are in this category, out of 33 total.