COBOL Program structure
https://www.tutorialspoint.com/cobol/cobol_program_structure.htm
STOP
RUN à Should be used only in main
program/calling program
Stops
the program execution and returns the control to OS
EXIT
PROGRAM à Should
be used only in sub program/called program
Returns
the control to main program/calling program
GO
BACK à Can be used in main program (or) sub
program
Returns
the control to sub program/called program
Figurative constants
http://mainframe-tips-and-tricks.blogspot.com/2011/12/cobol-what-exactly-low-values-and-high.html
Datatype justification
https://www.mainframestechhelp.com/tutorials/cobol/cobol-data-type-justifications.htm
Computational fields
Comp - https://www.mainframestechhelp.com/tutorials/cobol/cobol-computation.htm
Comp-1 - https://www.mainframestechhelp.com/tutorials/cobol/cobol-comp-1.htm
Comp-2 - https://www.mainframestechhelp.com/tutorials/cobol/cobol-comp-2.htm
Comp-3 - https://www.mainframestechhelp.com/tutorials/cobol/cobol-comp-3.htm
Assigning values to
variables
1.
value clause --> used in data division in COBOL
Value clause is an optional
clause which is used to initialize the data items. The values can be numeric
literal, alphanumeric literal, or figurative constant. It can be used with both
group and elementary items.
Example
WORKING-STORAGE SECTION.
01 WS-NUM1 PIC 99V9 VALUE
IS 3.5.
01 WS-NAME PIC A(6) VALUE 'ABCD'.
2.
Move --> move statements used in procedure division
MOVE
1111 TO LS-STUDENT-ID
3.
Accept values in COBOL program from JCL SYSIN dd *
http://www.techtricky.com/cobol-accept-statement/
4.
PARM in Run JCL and using Linkage section
http://www.mainframegurukul.com/srcsinc/drona/programming/languages/jcl/jcl.chapter4.html
Inspect
http://www.mainframegurukul.com/tutorials/programming/cobol/cobol-inspect.html
Condition names/88 level
number
http://www.techtricky.com/cobol-88-level-number-with-examples/
77 level number à variables which need not be
subdivided can be defined in 77 level number
66 level number
à https://www.mainframestechhelp.com/tutorials/cobol/cobol-renames-clause.htm
Redefines à https://www.mainframestechhelp.com/tutorials/cobol/cobol-redefines.htm
Subroutines
https://www.tutorialspoint.com/cobol/cobol_subroutines.htm