Getting error while executing REXX through JCL



IBM's Command List programming language & Restructured Extended Executor

Getting error while executing REXX through JCL

Postby debraj » Tue Apr 23, 2013 6:13 pm

Hi,

I am executing a REXX programe through JCL. But getting an error message as below:

RetCode=RXSUBCOM( 'ADD','DSNREXX', 'DSNREXX')
Error running FCHKPRIC, line 83: Routine not found


I am using below JCL:
//STEP01 EXEC PGM=IKJEFT01,REGION=0m,TIME=1440,PARM='FCHKPRIC'
//SYSEXEC DD DSN='rexx library containing rexx program FCHKPRIC',DISP=SHR
//SYSTSPRT DD SYSOUT=*
//SYSIN DD DUMMY
/*

NOTE: No error is faced while executing the REXX program directly using EX command. But when executing it via JCL it gives the error message in bold.
I am adding the below TSO libraries before executing the REXX programs.
ALLOC FILE(REXX) DATASET('xxxA.SDSNLOAD','xxxA.SDSNEXIT') SHR REUSE
TSOLIB ACTIVATE FILE(REXX)
debraj
 
Posts: 7
Joined: Thu Apr 18, 2013 8:00 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Getting error while executing REXX through JCL

Postby Akatsukami » Tue Apr 23, 2013 6:28 pm

And why do you think that that ALLOCATE statement is of any value whatsoever?
"You have sat too long for any good you have been doing lately ... Depart, I say; and let us have done with you. In the name of God, go!" -- what I say to a junior programmer at least once a day
User avatar
Akatsukami
Global moderator
 
Posts: 1058
Joined: Sat Oct 16, 2010 2:31 am
Location: Bloomington, IL
Has thanked: 6 times
Been thanked: 51 times

Re: Getting error while executing REXX through JCL

Postby debraj » Tue Apr 23, 2013 6:58 pm

The REXX code gives error without adding the ALLOCATE statement.
debraj
 
Posts: 7
Joined: Thu Apr 18, 2013 8:00 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Getting error while executing REXX through JCL

Postby Pedro » Tue Apr 23, 2013 9:11 pm

You are correct that a 'routine not found' error is likely because of a missing allocation.

If you are missing some allocation in the JCL, and you know the names of the datasets, then the solution is to add the allocation of those datasets to the JCL.
Pedro Vera
User avatar
Pedro
 
Posts: 684
Joined: Thu Jul 31, 2008 9:59 pm
Location: Silicon Valley
Has thanked: 0 time
Been thanked: 53 times

Re: Getting error while executing REXX through JCL

Postby dick scherrer » Tue Apr 23, 2013 10:19 pm

Hello and welcome to the forum,

Suggest you change the TIME=1440 to something else. . .

1440 is unacceptable on well-managed systems.
Hope this helps,
d.sch.
User avatar
dick scherrer
Global moderator
 
Posts: 6268
Joined: Sat Jun 09, 2007 8:58 am
Has thanked: 3 times
Been thanked: 93 times

Re: Getting error while executing REXX through JCL

Postby debraj » Wed Apr 24, 2013 4:51 pm

Hi Pedro,

I know the dataset name. Can you please tell how to allocate the dataset to JCL.



Hi dick scherrer,

I have also tried the same without the TIME parameter. But it shows the same error then.
debraj
 
Posts: 7
Joined: Thu Apr 18, 2013 8:00 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Getting error while executing REXX through JCL

Postby enrico-sorichetti » Wed Apr 24, 2013 4:54 pm

//....  EXEC ...
//STEPLIB DD ...
//        DD ...
cheers
enrico
When I tell somebody to RTFM or STFW I usually have the page open in another tab/window of my browser,
so that I am sure that the information requested can be reached with a very small effort
enrico-sorichetti
Global moderator
 
Posts: 2994
Joined: Fri Apr 18, 2008 11:25 pm
Has thanked: 0 time
Been thanked: 164 times

Re: Getting error while executing REXX through JCL

Postby NicC » Wed Apr 24, 2013 4:55 pm

You allocate the dataset name same as any other:
//ddname DD DSN=....DISP=...etc

Do not allocate it within your program.

The TIME parameter has no connection with your problem - Dick is just saying that you should not use it as it may be meaningless within your organisation and, in my opinion, it is better on the jobcard rather than being hidden away on a step.
The problem I have is that people can explain things quickly but I can only comprehend slowly.
Regards
Nic
NicC
Global moderator
 
Posts: 3025
Joined: Sun Jul 04, 2010 12:13 am
Location: Pushing up the daisies (almost)
Has thanked: 4 times
Been thanked: 136 times

Re: Getting error while executing REXX through JCL

Postby debraj » Wed Apr 24, 2013 5:26 pm

Hi Enrico,

BIG Thanks! It worked! :)
debraj
 
Posts: 7
Joined: Thu Apr 18, 2013 8:00 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Getting error while executing REXX through JCL

Postby dick scherrer » Wed Apr 24, 2013 8:22 pm

Hello,

The TIME=1440 had Nothing to do with the error.

You should NOT use TIME=1440.
Hope this helps,
d.sch.
User avatar
dick scherrer
Global moderator
 
Posts: 6268
Joined: Sat Jun 09, 2007 8:58 am
Has thanked: 3 times
Been thanked: 93 times

Next

Return to CLIST & REXX

 


  • Related topics
    Replies
    Views
    Last post