Upload
ravikiran8p
View
214
Download
0
Embed Size (px)
Citation preview
7/27/2019 COBOL_Training_Class-2.ppsx
1/12
IBM-Mainframes
COBOL CLASS-2
7/27/2019 COBOL_Training_Class-2.ppsx
2/12
So far we have Covered
Background and History of COBOL.
Structure of COBOL Program.
COBOL Program Organization (Division).
ID!"I#IC$"IO! DI%ISIO!
!%I&O!'!" DI%ISIO!
D$"$ DI%ISIO!
P&OCD& DI%ISIO!
COBOL LayoutCOBOL Code S*eet
'y #irst COBOL Program
7/27/2019 COBOL_Training_Class-2.ppsx
3/12
Preparation for COBOL Programs
"*ree im+ortant ste+s,
1. Write a COBOL Program.
2. Compile the Program.
3. Execute the Program..Com+i-ation, Process of converting from source code to
o/ect code
.For every COBOL program we nee to compile u!ing "CL.
#he compile "CL will $e !tanar %or the all the program&!.
."u!t we nee to copy the compile "CL %rom the exi!ting
'ata!et an ma(e the nece!!ary change!.
7/27/2019 COBOL_Training_Class-2.ppsx
4/12
Preparation for COBOL Program
7/27/2019 COBOL_Training_Class-2.ppsx
5/12
JCLJob contro Lang!age
7/27/2019 COBOL_Training_Class-2.ppsx
6/12
Short Introd!ction on JCL
JCL is used to compile and execute batch programs.
To write any JCL we require
"# JOB Statement#
2# $%$C Statement#
'' Statement#
(# )! Statement#
JOB* Execution of one or more programs is knows as a job
7/27/2019 COBOL_Training_Class-2.ppsx
7/12
JCL Statement+s
0OBS"$"'!", "OB !tatement i! u!e to ienti%y the "OB )ame
an "OB&! relate parameter! *accounting in%o+ u!ername+ cla!!+ noti%y
etc,.
-yntax
//"OB)0E"OB 0CC#)FO+-E4)0E+CL0--+)O#F5..
$ccountingInformation, I! mainly u!e %or $illing purpo!e.
sername, I! u!e to ienti%y who ha! written the "CL.
C-ass, I! u!e to provie re!ource con!traint to the 6o$.
!otify, ! u!e to ecie to which S&1IDthe "OB ha! to $e noti%y
a%ter !ucce!!%ul or un!ucce!!%ul compilation
7/27/2019 COBOL_Training_Class-2.ppsx
8/12
JCL Statement+s contd##
2C Statement,#hi! !tatement i! u!e to ienti%y the !tep name an
program name. 0 maximum we can write 277 !tatement! in a !ingle
"OB.
Synta3,
S"P4 2CP5'6P&O5 !$'
DDstatement, ! u!e to !peci%y the input an output location re8uire
%or a program execution/compilation.
Synta3, DD!$' DDP$&$'"&S
7/27/2019 COBOL_Training_Class-2.ppsx
9/12
JCL Statement+s contd##
DD name7s
S"PLIB, #hi! i! u!e to ienti%y the path o% the loa moule
*L language coe,.
S8SP&I!", #hi! i! u!e to print the error me!!age! in the !pool.
S8SO", % the program i! !ucce!!%ul the o/p will $e route to
-5-O# in the !pool.
it i! u!e to inicate the en o% the "CL.
7/27/2019 COBOL_Training_Class-2.ppsx
10/12
JCL Coding Sheet
49:111111111COL'! !'B&S111111;9;:111111111111111111 9>:? 99COE)#-99
Every !tatement in "CL are precee $y
)ame %iel "OB )ame+ -tep )ame an '' name
-tatement Fiel! "OB+ E:EC+ '' -tatement
Comment #o ma(e any comment in the "CL program we nee
to coe @
En o% "CL i! !peci%ie $y)ull !tatementi.e.+
7/27/2019 COBOL_Training_Class-2.ppsx
11/12
Sampe $,ec!tion JCL
0OB!$' 0OB 49:>7S$H$S&$7>CL$SS6$>!O"I#86AS8SID
S"P4 2C P5'6DISP5'
S"PLIB DD DS!6S&ID.!$'.LO$DLIB>DISP6SH&
S8SP&I!" DD S8SO"6@
S8SO" DD S8SO"6@
7/27/2019 COBOL_Training_Class-2.ppsx
12/12
han. /o!
ny !uires