You will see a list of reports in your spool file. It will look like:
Device or Total
Opt File User Queue User Data Sts Pages
QSYSPRT AIRPGMR PRTDGM RDY 1
QPJOBLOG AIRPGMR QPRINT AIRNRA RDY 2
QSYSPRT AIRPGMR PRTDGM RDY 1
QSYSPRT AIRPGMR PRTDGM RDY 1
QPJOBLOG AIRPGMR QPRINT TQE07 RDY 2
QSYSPRT AIRPGMR PRTDGM RDY 1
QSYSPRT AIRPGMR PRTDGM RDY 1
Each line is the name of a report on your Spool File. The most recent
reports are at the bottom. Key a 5 next the report you want to view.
You should now be looking at the compiler listing. To quickly locate errors,
key B (for bottom) in the CONTROL field and hit ENTER. You are now looking
at the bottom of the compiler report.
If your program compiled successfully, the last few lines will look like:
* * * * * E N D O F F I N A L S U M M A R Y * * * *
Program CMNR020 placed in library AIR. 00 highest severity. Created on
* * * * * E N D O F C O M P I L A T I O N * * * * *
If not, it will look more like:
* * * * * E N D O F F I N A L S U M M A R Y
Compilation stopped. Severity 30 errors found in program.
* * * * * E N D O F C O M P I L A T I O N * *
To find the errors, hit the PAGE UP key until you see:
* * * * * E N D O F E X T E R N A L R E F E R E N C E S * *
5769RG1 V4R2M0 980228 RN IBM ILE RPG AIR/CMNR020
M e s s a g e S u m m a r y
Msg id Sv Number Message text
*RNF7031 00 61 The name or indicator is not referenced.
*RNF7066 00 1 Record-Format name of Externally-Described file is not
*RNF7030 30 1 The name or indicator is not defined.
*RNF7503 30 1 Expression contains an operand that is not defined.
* * * * * E N D O F M E S S A G E S U M M A R Y * * * *
These are the errors that need correcting. Anything with severity level 00
is NOT an error.
To find the error, go to the top of the report. Do this by keying T in the
CONTROL field and hitting ENTER.
Then, key the error message ID in the FIND field. In this case, I keyed RNF7030 in the FIND field. Then, hit F16 to search. Remember F16 is SHIFT / F4.
In my case, the errors look like:
*RNF7066 00 2 000200 Record-Format CUSREC not used for
*RNF7030 30 123 005200 The name or indicator SYSDTECC is
*RNF7503 30 123 005200 Expression contains an operand tha
The errors RMF7030 and RNF7503 need to be fixed. They are both
related to sequence # 123 in the compile listing which is line number 52.00
in the source file.
In my case, I misspelled a variable name. This caused 2 errors.
Often, 1 error will cause more than 1 error message.
Tidak ada komentar:
Posting Komentar