Go BackMigration to the New COBOL Language

Synopsis
This course presents general programming concepts, terminology and specific coding requirements essential for migrating OS/VS COBOL programs to the ANSI 85 COBOL standard, including the 1989 addendum.  It also introduces IBM's implementation of object-oriented extensions to the COBOL language.

Audience
This course is for COBOL programmers

Time
6-11 hours, based on a student interacting with approximately 60 - 120 screens per hour.

Product Code: COB303
After completing this course, the student should be able to:
 
Describe the features of the ANSI 85 COBOL standard
Describe the benefits of using IBM's Language Environment
Explain how to terminate a COBOL statement
Code nested procedures
Describe types of loop structures
Code a case structure
Code intrinsic functions to perform arithmetic and date calculations
Code subprogram linkages
Create load modules using new compiler options
Debug a program

Unit A: COBOL Options
Compares the options offered by OS/VS COBOL, VS COBOL II, COBOL 370 and COBOL for MVS and VM.
 
Product Comparisons
The ANSI 85 Standard.  The Language Environment Product.  New Features of VS COBOL II, COBOL 370 and COBOL for MVS and VS.
Advantages of the New COBOL
Using 31-bit addresses.  High Precision Math Routines.  Year 2000 coding solutions.  GUI development interface.
Overview of Object-Oriented Extensions
CLASS definition.  INVOKE statement.  METHOD definition.  REPOSITORY paragraph.  Specifying an alternate reserved word table.  


Unit B:  Logical Structures
Covers the differences between implicit and explicit terminators.  Explains how to use END instead of a period.  Discusses nesting.
 
I/O Scope Terminators
Using END-READ, END-WRITE, END-REWRITE, END-DELETE, END-START.
IF Statements
Nesting IFs.  Eliminating NEXT SENTENCE.  Coding END-IF.  The difference between CONTINUE and NEXT SENTENCE.
Arithmetic Statements
Coding END-ADD, END-SUBTRACT, END-MULTIPLY, END-DIVIDE, END-COMPUTE.
Inline PERFORM loops
Types of loops.  Using psuedocode.  Coding END-PERFORM.  
Case Structures
Definition of a case structure.  The EVALUATE statement.  Testing relational conditions.  Coding END-EVALUATE.


Unit C: Language Changes and Enhancements
Explains new features of COBOL.  Describes advantages of new statements.  Covers how to update old OS/VS COBOL statements.
 
Data Options
Using the INITIALIZE statement.  The REPLACING BY clause.  Selective initialization.  Manipulating index items.  Setting program flags.  Using SET instead of MOVE.  Tables and indexing.  Relational operator symbols.  Negative logic.  De-editing numerics.  
Strings
Hexadecimal literals.  FILLER as an option.  Non-numeric literals.  UNSTRING subscripts.  Null-terminated strings.  Delimiters.  Specifying case.
Handling Files
The FILE STATUS clause.  Using VSAM file status codes.  Sorting and merging multiple files.  Handling duplicates.
Language Incompatibilities
Optional paragraph names.  Changing unsupported OS/VS COBOL statements.


Unit D: Built-in Functions
Explains how functions are used.  Covers situations where functions give more programming flexibility.  
 
Numeric Calculations
Identifying a function.  Types of numeric functions.  Arguments.  Fixed vs. floating point evaluation.  Arithmetic expressions.  Evaluating data items.  Random numbers.  Converting character strings to numbers.  
Special Calculations
Special registers vs. system information.  Using 4 digit dates.  Date and time calculations.  Using the ALL subscript in processing table items.  Financial applications.  Trigonometry and statistics.


Unit E: Combining Programs
Describes how to use subprograms.  Covers using programs written in different languages.  Explains types of program links.  Discusses options for mixing older COBOL load modules.  
 
Subprograms and Interoperability
Format of the CALL statement.  Choices of passing data to subprograms.  BY VALUE and BY REFERENCE.  LOCAL-STORAGE Section.  CALL ...RETURNING statement.  Defining pointers.  PROCEDURE-POINTER.
Program Linkage
Differences between static and dynamic calls.  Resolving calls by the binder.  Specifying addressing mode.  Determining program residence.  Mixing load modules.  Using the IGZBRDGE macro.  31-bit operating requirements.  Load module attributes.  RES and RENT options.  Overriding defaults.  


Unit F: Using Compilers
Covers adding compiler directives to the COBOL source code.  Explains how to use the new compiler options.
 
Compiler-directing Statements
Defining listing titles.  Format of the TITLE statement.  Controlling the amount of compiler output.  CONTROL statement.  Assigning compiler options in the source code.  PROCESS compiler directive.  
Compiler Options
The CMPR2 options.  Equivalent compiler options.  Compiler options DATA, FASTSRT, FDUMP, NUMPROC, RENT, SSRANGE, WORD, NOSSRANGE, DUMP.  Flag options.  Compiler error codes.  



Unit G: Debugging
Explains how to add debugging statements to the COBOL source.  Describes debugging compiler options.  Describes CODE/370.  Covers debugging a program interactively using the Debug tool.
 
Source Language Debugging
Tracing logic.  Using the DISPLAY statement.  Handling I/O errors.  Checking data class.  Forcing data values.  Compiler Options.
CODE/370
Language sensitive editing.  Online help. Overview of the Debug tool.  Adding source code hooks.  The TEST compiler option.  Interactive debugging requirements.  


 

Go Back