MainframeMaster

COBOL Tutorial

SKIP3 - Insert Three Blank Lines

Progress0 of 0 lessons

Usage

SKIP3 adds three blank lines—a strong visual separator—commonly before report-wide summaries or between chapters.

COBOL Implementation

cobol
1
WRITE PRINT-REC AFTER ADVANCING 3 LINES

Guard for page end

cobol
1
2
3
4
IF LINE-COUNTER > PAGE-LIMIT - 3 WRITE PRINT-REC AFTER ADVANCING PAGE END-IF WRITE PRINT-REC AFTER ADVANCING 3 LINES

Non-Code Scenarios

  • Before a grand summary at the very end of the report
  • Between yearly sections in a consolidated report

Quick Reference

ActionSyntaxNote
Three blanksWRITE ... AFTER ADVANCING 3 LINESStrong separator
GuardIF LINE-COUNTER > PAGE-LIMIT - 3Advance PAGE first

Test Your Knowledge

1. COBOL equivalent of SKIP3?

  • WRITE AFTER ADVANCING 3 LINES
  • DISPLAY AT 3,1
  • READ NEXT 3
  • COMPUTE

2. What to check before SKIP3?

  • Remaining lines on page
  • Sort sequence
  • SQLCODE
  • DATE FORMAT

Frequently Asked Questions

Related Pages