EJECT Verb in COBOL

This is a Mainframe COBOL forum - you can post your queries on Mainframe COBOL, VS COBOL II, COBOL/370 , Enterprise COBOL

Moderators: dbzTHEdinosauer, Moderator Group

Post Reply
User avatar
Vamsi99
Active Member
Posts: 183
Joined: Wed Nov 05, 2008 11:20 am

EJECT Verb in COBOL

Post by Vamsi99 » Tue May 19, 2009 11:27 am

What is EJECT verb in COBOL?
In our project, i have seen this verb in old programs. Not sure what it will do.

User avatar
dbzTHEdinosauer
Moderator
Posts: 981
Joined: Mon Oct 02, 2006 8:31 pm

Post by dbzTHEdinosauer » Tue May 19, 2009 2:12 pm

here is a link for all the cobol documentation in the IBM library server. Suggest you pick the manual that fits your site's COBOL.
Dick Brenholtz
JCL, SQL and code in programs have an irritating habit of doing what you say,
not what you meant.

User avatar
Natarajan
Moderator
Posts: 537
Joined: Fri Oct 10, 2008 12:57 pm
Location: chennai
Contact:

Post by Natarajan » Tue May 19, 2009 5:59 pm

The EJECT statement has no effect on the compilation of the source unit itself.
EJECT is compiler directing statement in COBOL.

The EJECT statement specifies that the next source statement is to be printed at the top of the next page.
When compiler prints the listings of COBOL source code all the lines after EJECT will be next new page. EJECT wont get printed in listing.

SKIP is another similar kind of statement - SKIP n
It will skip n lines before continuing to print.

Syntax rules -
EJECT should be only one statement on that line
can be termined with period.
can be written in area A or area B.
Natarajan
Chennai

Shashank Gite
Member
Posts: 4
Joined: Tue Feb 24, 2009 3:54 pm
Location: Pune

Post by Shashank Gite » Tue Jun 16, 2009 4:49 pm

Absolutely correct I agree with you Natarajan.
Cheers...
Shashank Gite

madhureddygs
Member
Posts: 8
Joined: Wed Apr 01, 2009 11:25 am

Post by madhureddygs » Mon Jul 13, 2009 1:56 pm

This is useful information for me also. Thanks everyone. :D

prasannag
Member
Posts: 1
Joined: Fri Aug 28, 2009 9:53 am
Location: Chennai

Post by prasannag » Fri Aug 28, 2009 11:33 am

This gave me solution for longunanswered question...Thanks to all...
GPVK

academyindia4

Topic deleted by Admin

Post by academyindia4 » Mon Feb 01, 2016 10:17 pm

<< Content deleted By Admin >>

Post Reply

FREE TUTORIALS

Tutorials
Free tutorials from mainframegurukul
  • JCL Tutorial
    Covers all important JCL concepts.
  • Cobol Tutorial
    This tutorials covers all Cobol Topics from STRING to COMP-3.
  • DB2 Tutorial
    DB2 Tutorial focuses on DB2 COBOL Programming.
  • SORT Tutorial
    This Tutorial covers all important aspects of DFSORT with examples
  • CICS Tutorial
    This CICS tutorial covers CICS concepts and CICS Basics, CICS COBOL Programming.
Interview
Mainframe Interview questions



Other References
Mainframe Tools and others