Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
Difference between GOBACK and RETURN?

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> COBOL Programming
View previous topic :: :: View next topic  
Author Message
asvijay

New User


Joined: 13 Jul 2006
Posts: 11

PostPosted: Fri Jul 28, 2006 12:30 pm    Post subject: Difference between GOBACK and RETURN?
Reply with quote

Hi,
In subroutine, what is the difference of usage in GOBACK and RETURN?
Back to top
View user's profile Send private message

shreevamsi

Active User


Joined: 23 Feb 2006
Posts: 305
Location: Hyderabad,India

PostPosted: Fri Jul 28, 2006 12:52 pm    Post subject: Re: Difference between GOBACK and RETURN?
Reply with quote

Hi Vijay,

This topic has been discussed many a time in the forum.
Please search the forum before you post.

Anyhow,

In the case of a Subroutine,

If a GOBACK is coded at the end of the routine. the control goes back to the Called program.
If a Stop Run is coded, the execution terminates and the control goes back to the MVS.

~Vamsi
Back to top
View user's profile Send private message
shreevamsi

Active User


Joined: 23 Feb 2006
Posts: 305
Location: Hyderabad,India

PostPosted: Fri Jul 28, 2006 1:01 pm    Post subject: Re: Difference between GOBACK and RETURN?
Reply with quote

For information abt RETURN, please follow

http://ibmmainframes.com/viewtopic.php?t=1096&highlight=returncode
Back to top
View user's profile Send private message
asvijay

New User


Joined: 13 Jul 2006
Posts: 11

PostPosted: Fri Jul 28, 2006 1:15 pm    Post subject:
Reply with quote

Hi Vamsi,
I did not ask the difference between GOBACK and STOP RUN i just asked diff bn GO BACK and RETURN...i heard the RETURN is also the word can be used to get back the control of subroutine for main program..
Can u help me?
Back to top
View user's profile Send private message
DavidatK

Active Member


Joined: 22 Nov 2005
Posts: 700
Location: Troy, Michigan USA

PostPosted: Fri Jul 28, 2006 7:06 pm    Post subject: Re: Difference between GOBACK and RETURN?
Reply with quote

The 'RETURN' statement is not the same as the 'GOBACK' statement.

Please read the RETURN STATEMENT from the IBM COBOL Manual

If you still have confusion, please come back

Dave
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> COBOL Programming All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Difference in SORT & ICETOOL Mohan Kothakota DFSORT/ICETOOL 4 Fri Sep 22, 2017 4:56 pm
No new posts Return a Non Numeric value from REXX Learncoholic CLIST & REXX 3 Fri Sep 01, 2017 8:33 pm
No new posts EXIT or RETURN cvnlynn CLIST & REXX 18 Wed Jul 19, 2017 2:50 am
No new posts QUESTION: RETURN CHANNEL pahiker CA Products 21 Thu Apr 20, 2017 12:31 am
No new posts JCL to Set Return code based on DB2 S... vinu78 DB2 17 Mon Mar 13, 2017 9:47 pm

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us