View previous topic :: View next topic
|
Author |
Message |
shreejita
New User
Joined: 16 Aug 2009 Posts: 60 Location: chennai
|
|
|
|
Hi All,
I tried executing REXX program using following jcl and it works fine.
Code: |
//USERAA JOB (),NOTIFY=&SYSUID
//**********************************************************
//* JCL TO CALL REXX IN BATCH
//**********************************************************
//TSO EXEC PGM=IKJEFT01,PARM='%MAIN'
//SYSTSPRT DD SYSOUT=*
//SYSTSIN DD DUMMY
//SYSEXEC DD DSN=USERAA.MYPDS.REXX,DISP=SHR
//
|
My Question is for EXTERNAL SUBROUTINE concept it does not work.When i run MAIN program it says SOC4 , subpogram not linked .
My MAIN program is
/* REXX MAIN PROGRAM*/
SAY "BEFORE subpgm CALLED "
CALL MYSUB
SAY " I AM IN MAIN AGAIN "
EXIT
/* REXX SUBPROGRAM mysub */
SAY 'SUB PROGRAM'
RETURN
help Me. |
|
Back to top |
|
|
kacks7
New User
Joined: 22 Sep 2010 Posts: 33 Location: chennai(india)
|
|
|
|
hi
its executing fine.
my o/p is
BEFORE SUBPGM CALLED
SUB PROGRAM
I AM IN MAIN AGAIN
READY
END
Quote: |
//USERAA JOB (),NOTIFY=&SYSUID
//**********************************************************
//* JCL TO CALL REXX IN BATCH
//**********************************************************
//TSO EXEC PGM=IKJEFT01,PARM='%MAIN'
//SYSTSPRT DD SYSOUT=*
//SYSTSIN DD DUMMY
//SYSEXEC DD DSN=USERAA.MYPDS.REXX,DISP=SHR
//
|
check with this jcl
Code: |
//*
//* ENTER YOUR JOB CARD HERE
//***************************************************************
//* JCL TO CALL REXX IN BATCH
//***************************************************************
//*
//* CHANGE TO BE MADE :
//* XXXXXX.YYYYYY - THE LIBRARY WHERE YOUR REXX PGM EXISTS
//* PPPPPP - THE MEMBER NAME OF YOUR REXX PROGRAM
//*
//***************************************************************
//RXNBATCH EXEC PGM=IKJEFT01
//SYSEXEC DD DSN=XXXXXX.YYYYYY,DISP=SHR
//SYSTSPRT DD SYSOUT=*
//SYSTSIN DD *
%PPPPPPPP
/*
// |
|
|
Back to top |
|
|
shreejita
New User
Joined: 16 Aug 2009 Posts: 60 Location: chennai
|
|
|
|
HI,
Yes i tried that too but no changes. Same error with SOC4 error, subprogram is not linked.
Thanks |
|
Back to top |
|
|
enrico-sorichetti
Superior Member
Joined: 14 Mar 2007 Posts: 10872 Location: italy
|
|
|
|
there is nothing wrong with the initial jcl
( apart the odd name MAIN for the rexx )
kacks7 suggestion was lets' say irrelevant
use the trace statement to see what is going on in Your rexx |
|
Back to top |
|
|
shreejita
New User
Joined: 16 Aug 2009 Posts: 60 Location: chennai
|
|
|
|
HI,
I tried both having in one PDS member , it works correctly , but my question is both MAIN and SUB are in different member of same PDS.
Please reply... |
|
Back to top |
|
|
enrico-sorichetti
Superior Member
Joined: 14 Mar 2007 Posts: 10872 Location: italy
|
|
|
|
I just checked...
it works also if the main and the subroutine are in different members |
|
Back to top |
|
|
shreejita
New User
Joined: 16 Aug 2009 Posts: 60 Location: chennai
|
|
|
|
Thanks a lot everybody...
It is working.....Great to have this forum ...all credit goes to you for prompt reply.
Thanks |
|
Back to top |
|
|
kacks7
New User
Joined: 22 Sep 2010 Posts: 33 Location: chennai(india)
|
|
|
|
hi,
may i know wat problem causing the SOC4 error??? |
|
Back to top |
|
|
superk
Global Moderator
Joined: 26 Apr 2004 Posts: 4652 Location: Raleigh, NC, USA
|
|
|
|
Hmm, odd, it worked just fine for me, with MAIN and MYSUB being two different members in the same PDS. |
|
Back to top |
|
|
kacks7
New User
Joined: 22 Sep 2010 Posts: 33 Location: chennai(india)
|
|
|
|
enrico-sorichetti wrote: |
kacks7 suggestion was lets' say irrelevant
|
i just executed by keeping the main and sub program in diff members of a pds and showed my output what i got. is this irrelavent??? |
|
Back to top |
|
|
enrico-sorichetti
Superior Member
Joined: 14 Mar 2007 Posts: 10872 Location: italy
|
|
|
|
Looks like You didn' t read my post with the due attention !
and also You posted a suggestion about changing the JCL
the above suggestion was ... useless |
|
Back to top |
|
|
|