Documente Academic
Documente Profesional
Documente Cultură
Selection or command
===> 3
Start PDM (using STRPDM) and when the above screen is displayed select option 3
and press Enter.
Specify Members to Work With
Member:
Name . . . . . . . . . *ALL *ALL, name, *generic*
Type . . . . . . . . . *ALL *ALL, type, *generic*, *BLANK
Enter your library name (instead of library MOHAMED) and then press Enter.
Work with Members Using PDM ODIN
File . . . . . . QCBLSRC
Library . . . . MOHAMED Position to . . . . .
Bottom
Parameters or command
===>
F3=Exit F4=Prompt F5=Refresh F6=Create
F9=Retrieve F10=Command entry F23=More options F24=More keys
Additional Parameters
Bottom
F3=Exit F4=Prompt F5=Refresh F10=Additional parameters F12=Cancel
F13=How to use this display F24=More keys
In order to use the Interactive Source Debugger later on, you have to change the
compile options in this screen. To do that press F10.
Create COBOL Program (CRTCBLPGM)
Additional Parameters
More...
F3=Exit F4=Prompt F5=Refresh F12=Cancel F13=How to use this display
F24=More keys
Enter *SRCDBG as the Source listings option and then press Enter.
Confirm Compile of Member
F12=Cancel
To replace the old compiled version of the program enter ‘Y’ and then press Enter.
Work with Members Using PDM ODIN
File . . . . . . QCBLSRC
Library . . . . MOHAMED Position to . . . . .
Bottom
Parameters or command
===>
F3=Exit F4=Prompt F5=Refresh F6=Create
F9=Retrieve F10=Command entry F23=More options F24=More keys
The compile of member SENIOR was submitted to batch. +
File . . . . . . QCBLSRC
Library . . . . MOHAMED Position to . . . . .
Bottom
Parameters or command
===> WRKSBMJOB *JOB
F3=Exit F4=Prompt F5=Refresh F6=Create
F9=Retrieve F10=Command entry F23=More options F24=More keys
Job 342470/MOHAMED/SENIOR submitted to job queue QBATCH in library QGPL.
Bottom
Parameters or command
===>
F3=Exit F4=Prompt F5=Refresh F9=Retrieve F11=Display schedule data
F12=Cancel
Bottom
Parameters for options 1, 2, 3 or command
===>
F3=Exit F10=View 3 F11=View 2 F12=Cancel F22=Printers F24=More keys
To view the compiled program spool file enter option 5 and press Enter.
Display Spooled File
File . . . . . : SENIOR Page/Line 1/1
Control . . . . . B Columns 1 - 130
Find . . . . . . _____________________________
*...
+....1....+....2....+....3....+....4....+....5....+....6....+....7....+....8....+....9....+....0....+....1....+....2....+....3
5769CB1 V4R2M0 980228 IBM COBOL/400 MOHAMED/SENIOR
ODIN 10/03/99 17:45:53 Page 1
Program . . . . . . . . . . . . . . : SENIOR
Library . . . . . . . . . . . . . : MOHAMED
Source file . . . . . . . . . . . . : QLBLSRC
Library . . . . . . . . . . . . . : MOHAMED
Source member . . . . . . . . . . . : SENIOR 09/11/99 17:22:52
Generation severity level . . . . . : 29
Text 'description' . . . . . . . . . : The first Cobol program
Source listing options . . . . . . . : *SRCDBG
Generation options . . . . . . . . . : *NONE
Conversion options . . . . . . . . . : *NONE
Sort sequence . . . . . . . . . . . : *HEX
Library . . . . . . . . . . . . . :
Language identifier . . . . . . . . : *JOBRUN
Message limit:
Number of messages . . . . . . . . : *NOMAX
Message limit severity . . . . . . : 29
Print file . . . . . . . . . . . . . : QSYSPRT
Library . . . . . . . . . . . . . : *LIBL
More...
F3=Exit F12=Cancel F19=Left F20=Right F24=More keys
Enter B in the control field and press Enter to go to the bottom of the compile
listing.
Display Spooled File
File . . . . . : SENIOR Page/Line 4/34
Control . . . . . B Columns 1 - 130
Find . . . . . .
*...
+....1....+....2....+....3....+....4....+....5....+....6....+....7....+....8....+....9....+....0....+....1....+....2....+....3
* 44 MSGID: LBL0014 SEVERITY: 10 SEQNBR: 005900
Message . . . . : Delimiter for literal is not correct.
Literal accepted.
* 49 MSGID: LBL0014 SEVERITY: 10 SEQNBR: 006500
Message . . . . : Delimiter for literal is not correct.
Literal accepted.
* * * * * E N D O F M E S SAG E S * * * * *
Message Summary
Total Info(0-4) Warning(5-19) Error(20-29) Severe(30-39) Terminal(40-99)
9 2 5 2 0 0
Source records read . . . . . . . . : 66
Copy records read . . . . . . . . . : 0
Copy members processed . . . . . . : 0
Sequence errors . . . . . . . . . . : 0
Highest severity message issued . . : 20
LBL0901 00 Program SENIOR created in library MOHAMED on 10/03/99 17:46:22.
5769CB1 V4R2M0 980228 AS/400 COBOL Messages MOHAMED/SENIOR ODIN 10/03/99 17:45:53 Page 5
STMT
* * * * * E N D O F C O M P I LAT I O N * * * * *
Bottom
F3=Exit F12=Cancel F19=Left F20=Right F24=More keys
The first highlighted line shows the number and type of errors found. The second
highlighted line states that the compilation was successful and that the program was
created in library MOHAMED (in your case the program must be created in your
own library).
Display Spooled File
File . . . . . : SENIOR Page/Line 4/8
Control . . . . . Columns 1 - 130
Find . . . . . . _________________
*...+....1....+....2....+....3....+....4....+....5....+....6....+....7....+....8....+....9....+....0....+....1....+....2....+....3
clause. System-name QPRINT assumed.
* 13 MSGID: LBL0116 SEVERITY: 20 SEQNBR: 001500
Message . . . . : Largest record description does not match
RECORD CONTAINS clause for file. '42' assumed.
Enter * 13 MSGID: LBL0117 SEVERITY: 20 SEQNBR: 001500
Statement Message . . . . : Smallest record description '42' characters.
number Does not match RECORD CONTAINS. '42' assumed.
* 13 MSGID: LBL0650 SEVERITY: 00 SEQNBR: 001500
and press Message . . . . : Blocking/Deblocking for file 'STUDENT-FILE'
F16 (shift will be performed by compiler-generated code.
F4) to * 28 MSGID: LBL0014 SEVERITY: 10 SEQNBR: 003200
Message . . . . : Delimiter for literal is not correct.
search for Literal accepted.
the * 37 MSGID: LBL0014 SEVERITY: 10 SEQNBR: 004500
statement. Message . . . . : Delimiter for literal is not correct.
Literal accepted.
* 39 MSGID: LBL0014 SEVERITY: 10 SEQNBR: 004900
Message . . . . : Delimiter for literal is not correct.
Literal accepted.
More...
F3=Exit F12=Cancel F19=Left F20=Right F24=More keys
If you have errors that exceed severity level 29 then your compile will fail and you
have to scroll up to look at the error messages generated.
Work with Job Spooled Files
Bottom
Parameters for options 1, 2, 3 or command
===> STRISDB
F3=Exit F10=View 3 F11=View 2 F12=Cancel F22=Printers F24=More keys
If the compile is successful then you can run the Interactive Source Debugger
(STRISDB) and press Enter.
Start ISDB (STRISDB)
Bottom
F3=Exit F4=Prompt F5=Refresh F10=Additional parameters F12=Cancel
F13=How to use this display F24=More keys
Enter the program name and library as shown (make sure the library is your
library name). If your program is called directly (i.e. you are not using a CL
program or another program to call your program) then enter *YES in the Invoke
program field.
Start ISDB (STRISDB)
Bottom
F3=Exit F4=Prompt F5=Refresh F10=Additional parameters F12=Cancel
F13=How to use this display F24=More keys
Press Enter.
Debug Goto Program Options Help
MOHAMED/SENIOR:/0001 ISDB/400 More: + >
000100 IDENTIFICATION DIVISION.
000200 PROGRAM-ID. SENIOR.
000300 AUTHOR. ROBERT GRAUER.
000400
000500 ENVIRONMENT DIVISION.
000600 INPUT-OUTPUT SECTION.
000700 FILE-CONTROL.
000800 SELECT STUDENT-FILE ASSIGN TO DATABASE-SENIORDAT
000900 ORGANIZATION IS SEQUENTIAL.
001000 SELECT PRINT-FILE
001100 ASSIGN TO PRINTER.
001200
001300 DATA DIVISION.
001400 FILE SECTION.
001500 FD STUDENT-FILE
001600 RECORD CONTAINS 43 CHARACTERS
001700 DATA RECORD IS STUDENT-IN.
001800 01 STUDENT-IN.
ISDB ===>
F3=Exit F5=Step F6=Break F11=Display variable
F12=Cancel F17=Run F23=Change variable F24=More keys
(C) COPYRIGHT IBM CORP. 1993, 1997.
You are now in the Interactive debug mode. Use the Function Keys (shown
highlighted) to debug your program. You can use the F1 help function to read the
help topics.
Debug Goto Program Options Help
MOHAMED/SENIOR:4200.1 ISDB/400 More: - + >
004200 OPEN INPUT STUDENT-FILE
004300 OUTPUT PRINT-FILE.
004400 READ STUDENT-FILE
004500 AT END MOVE 'NO' TO DATA-REMAINS-SWITCH
004600 END-READ.
004700 PERFORM WRITE-HEADING-LINE.
004800 PERFORM PROCESS-RECORDS
004900 UNTIL DATA-REMAINS-SWITCH = 'NO'.
005000 CLOSE STUDENT-FILE
005100 PRINT-FILE.
005200 STOP RUN.
005300
005400 WRITE-HEADING-LINE.
005500 MOVE HEADING-LINE TO PRINT-LINE.
005600 WRITE PRINT-LINE.
005700
005800 PROCESS-RECORDS.
005900 IF STU-CREDITS > 110 AND STU-MAJOR = 'ENGINEERING'
ISDB ===>
F3=Exit F5=Step F6=Break F11=Display variable
F12=Cancel F17=Run F23=Change variable F24=More keys
Stopped at statement 4200.1.
Note: The debugging starts at the first statement of the first paragraph of the
Procedure Division.
Debug Goto Program Options Help
MOHAMED/SENIOR:4200.1 ISDB/400 More: - + >
004200 OPEN INPUT STUDENT-FILE
004300 OUTPUT PRINT-FILE.
004400 READ STUDENT-FILE
004500 .............................................
004600 : Cancel ISDB :
004700 : :
004800 : You have requested to cancel ISDB. :
004900 : :
005000 : If you are servicing another :
005100 : job, enter the ENDISDB command :
005200 : afterward, to end debugging. :
005300 : :
005400 WR : Cancel ISDB . . . . . . 1 1=Yes, 2=No :
005500 : :
005600 : F12=Cancel :
005700 :...........................................:
005800 PROCESS-RECORDS.
005900 IF STU-CREDITS > 110 AND STU-MAJOR = 'ENGINEERING'
ISDB ===>
F3=Exit F5=Step F6=Break F11=Display variable
F12=Cancel F17=Run F23=Change variable F24=More keys
Stopped at statement 4200.1.