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
 
Moved value '16' to return-code

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

Active User


Joined: 02 Sep 2005
Posts: 189
Location: Noida

PostPosted: Mon May 15, 2006 3:19 pm    Post subject: Moved value '16' to return-code
Reply with quote

Hi,

i m having problem with return-code passing from cobol to jcl
my program is compiling perfectly
i moved value '16' to return-code
put a display of returncode also

but the job is executing with return-code =0
whereas in sysout t shows 16 ( display statements )

-Kapil .
Back to top
View user's profile Send private message

superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 4650
Location: Raleigh, NC, USA

PostPosted: Mon May 15, 2006 3:21 pm    Post subject: Re: Return-code
Reply with quote

Could you please post both the COBOL and JCL code?
Back to top
View user's profile Send private message
hikaps14

Active User


Joined: 02 Sep 2005
Posts: 189
Location: Noida

PostPosted: Mon May 15, 2006 5:20 pm    Post subject: Re: Return-code
Reply with quote

hi ,

The source Code :
Code:

 DATA DIVISION.                                                   

   WORKING-STORAGE SECTION.                                         

   PROCEDURE DIVISION.                                             

            MOVE +3000 TO RETURN-CODE                                   
            DISPLAY 'RETURN-CODE : ' RETURN-CODE                       
             STOP RUN.                                                   


the Coressponding Jcl :

Code:
               
                         
//*                                                                     
//STEP0010 EXEC PGM=prg1                                             
//UTLITYF  DD  DUMMY                                                   
//SYSPRINT DD SYSOUT=*                                                 
//SYSOUT   DD SYSOUT=*                                                 


This job is running with return code =0 , and display is still '3000'

could u plz c into it ,
do we need to provide anything else in code

Thanks ,
-Kapil .
Back to top
View user's profile Send private message
superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 4650
Location: Raleigh, NC, USA

PostPosted: Mon May 15, 2006 5:51 pm    Post subject: Re: Return-code
Reply with quote

Hmmm. Don't know what to say.

I get this:

Quote:

08.19.33 JOB12345 $HASP165 MYJOB ENDED AT MVSJESX MAXCC=3000 CN(INTERNAL)


and this in the SYSOUT DD:

Quote:

RETURN-CODE : 3000
Back to top
View user's profile Send private message
hikaps14

Active User


Joined: 02 Sep 2005
Posts: 189
Location: Noida

PostPosted: Tue May 16, 2006 11:53 am    Post subject: Re: Moved value '16' to return-code
Reply with quote

hi....

now i got the return code

i used GOBACK instead of StOP RUN .

but now can any body make me clear why it doesn't work with stop run .i also want to confirm if this is happenning with my system only or it happens always .
Back to top
View user's profile Send private message
hikaps14

Active User


Joined: 02 Sep 2005
Posts: 189
Location: Noida

PostPosted: Tue May 16, 2006 3:23 pm    Post subject: Re: Moved value '16' to return-code
Reply with quote

Hi ,

Sorry to disturb everyone ,
i think there is some problem in my compile job .
i don't think if there is any relation to GOBACK or STOP RUN .

sorry if i created any confusion .

Thanks ,
-Kapil .
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 Speed-up/reduce CPU use of code prino PL/I & Assembler 0 Tue Sep 26, 2017 12:05 am
No new posts Return a Non Numeric value from REXX Learncoholic CLIST & REXX 3 Fri Sep 01, 2017 8:33 pm
This topic is locked: you cannot edit posts or make replies. how to code for GDG in Rexx cvnlynn CLIST & REXX 13 Wed Aug 09, 2017 9:13 pm
This topic is locked: you cannot edit posts or make replies. rexx code to create a ps file Bharath Vikraman CLIST & REXX 4 Mon Aug 07, 2017 10:30 am
No new posts I want to retire TRX and use only Rex... Abhinav Sharma CLIST & REXX 6 Sat Jul 29, 2017 2:53 am

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