IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

how to get Job information from IOF using Rexx


IBM Mainframe Forums -> CLIST & REXX
Post new topic   This topic is locked: you cannot edit posts or make replies.
View previous topic :: View next topic  
Author Message
rsshanmugam

New User


Joined: 08 Mar 2005
Posts: 62
Location: Basildon

PostPosted: Mon Feb 05, 2018 4:22 pm
Reply with quote

I have been learning REXX recently, i have been developing tools in rexx, my current tool needs to submit job and based on job input i need to submit further job. in my shop we use IOF instead of SDSF. have gone through the tutorials (http://www.triangle-systems.com/doc/7j/UG7JC18.HTM) , but the code present in the tutorial is not working.

following is the code to scroll through IOF pane,

Code:

/* Rexx multi-environment example */             
/* Determine exec name and environment */         
parse source . . myname . . . . . myenv .         
uid =userid()                                     
/* If not IOF environment, re-invoke the exec */ 
/* under IOF */                                   
if myenv \= 'IOF' then do                         
/* push the IOF command including any parms. In */
/* this example there are no parms. */           
 push "IOF *.%"                                   
 CONTROL END(ENDO)                               
 lock                                             
 TSICOPY NAME(ROWS) SECTION(PANEL) TO(CLIST)     
 SET &CURROW = 1                                 
 DO WHILE &CURROW LE &ROWS                       
 TSICOPY NAME(JOBNAME JOBID) TO(CLIST)           
 WRITE &JOBNAME &JOBID                           
 say JOBNAME                                     
 say JOBID                                       
 DOWNCTRL                                           
 SET CURROW = &CURROW + 1                           
 ENDO                                               
 UNLOCK                                             
 exit                                               
 /* exit the initial exec */ end                   
/* If IOF environment, process IOF subcommands */   
else do                                             
say 'i am in IOf'                                   
 address IOF                                       
exit end






when i execute the above code, i am getting the following error.

Code:

RX0250E System abend code 66D, reason code 00000008.
RX0253E Abend in external function END.             
EA995I SYMPTOM DUMP OUTPUT                         
SYSTEM COMPLETION CODE=66D  REASON CODE=00000008                             
 TIME=10.34.19  SEQ=06231  CPU=4000  ASID=05D2                               
 PSW AT TIME OF ERROR  071C0000   8A1CBC26  ILC 2  INTC 0D                   
   NO ACTIVE MODULE FOUND                                                   
   NAME=UNKNOWN                                                             
   DATA AT PSW  0A1CBC20 - 41F00008  0A0D5850  B430B20A                     
   AR/GR 0: 00000001/00000000_80000005   1: 00000000/00000000_0466D000       
         2: 00000000/00000000_00000900   3: 00000000/00000000_00000005       
         4: 00000000/00000000_00A96158   5: 00000000/00000000_0006DFC4       
         6: 00000000/00000000_00000980   7: 00000000/00000000_00F08B80       
         8: 00000000/00000000_8A1CBB6A   9: 00000000/00000000_0006DF90       
         A: 00000000/00000000_0A1CD9E8   B: 00000000/00000000_00AB46EC       
         C: 00000000/00000000_8A1CB034   D: 00000000/00000000_00AB46EC       
         E: 00000000/00000000_00000000   F: 00000000/00000001_00000008       
 END OF SYMPTOM DUMP                                                         
    11 +++   CONTROL END(ENDO)                                               
IRX0040I Error running IOF, line 11: Incorrect call to routine



Could anyone please help to solve the issue.
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8797
Location: Welsh Wales

PostPosted: Mon Feb 05, 2018 4:24 pm
Reply with quote

What happened when you googled S66D-08 abend
Back to top
View user's profile Send private message
rsshanmugam

New User


Joined: 08 Mar 2005
Posts: 62
Location: Basildon

PostPosted: Mon Feb 05, 2018 4:27 pm
Reply with quote

A hexadecimal reason code identifies the error. This code appears either on user's terminal along with the abend notification, or in the dump taken for the
abend.

explanation for reason code:

An abend X'0C4' occurred when validating user pointers Start of changeor a pointer was set to zeroEnd of change


IBM Page: www.ibm.com/support/knowledgecenter/en/SSLTBW_2.1.0/com.ibm.zos.v2r1.ieah700/m015231.htm
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8797
Location: Welsh Wales

PostPosted: Mon Feb 05, 2018 4:41 pm
Reply with quote

This should show you the line causing the problems, then you'll need to find out why

Code:

SIGNAL ON SYNTAX NAME ERR
.
your code
.
ERR:
  SIGNAL OFF SYNTAX
  DROPBUF
  SAY "ERROR ROUTINE OUTPUT STARTING"
  SAY "ERROR ROUTINE OUTPUT STARTING"
  SAY "   "
  SAY RIGHT(SIGL,6) ">>>" SOURCELINE(SIGL)
  SAY "   "
Back to top
View user's profile Send private message
Nic Clouston

Global Moderator


Joined: 10 May 2007
Posts: 2455
Location: Hampshire, UK

PostPosted: Mon Feb 05, 2018 5:07 pm
Reply with quote

Quote:
RX0253E Abend in external function END
Back to top
View user's profile Send private message
rsshanmugam

New User


Joined: 08 Mar 2005
Posts: 62
Location: Basildon

PostPosted: Mon Feb 05, 2018 5:14 pm
Reply with quote

Exactly Nic, i am getting the abend at

Code:

CONTROL END(ENDO)


what should i do, these codes are suppose to open IOF, browse through each job and say the Jobname and Jobid.

once i am successful in this only, i can proceed in the next step.
Back to top
View user's profile Send private message
prino

Senior Member


Joined: 07 Feb 2009
Posts: 1306
Location: Vilnius, Lithuania

PostPosted: Mon Feb 05, 2018 8:04 pm
Reply with quote

REXX <> CLIST
Back to top
View user's profile Send private message
Nic Clouston

Global Moderator


Joined: 10 May 2007
Posts: 2455
Location: Hampshire, UK

PostPosted: Mon Feb 05, 2018 8:06 pm
Reply with quote

Is END an external function? What is the syntax of CONTROL? Is CONTROL some keyword of the IOF/Rexx interface?
Back to top
View user's profile Send private message
steve-myers

Active Member


Joined: 30 Nov 2013
Posts: 917
Location: The Universe

PostPosted: Mon Feb 05, 2018 8:25 pm
Reply with quote

What I'm seeing here is a weird mix of Rexx and CLIST.

CONTROL END(ENDDO) is CLIST as is SET &CURROW = 1

You can't use CLIST type statements in a Rexx exec.
Back to top
View user's profile Send private message
rsshanmugam

New User


Joined: 08 Mar 2005
Posts: 62
Location: Basildon

PostPosted: Mon Feb 05, 2018 9:00 pm
Reply with quote

i need code to read IOF output through REXX, i modified code as below.

Code:

SIGNAL ON SYNTAX NAME ERR                           
parse source . . myname . . . . . myenv .           
uid =userid()                                       
/* If not IOF environment, re-invoke the exec */     
/* under IOF */                                     
if myenv \= 'IOF' then do                           
/* push the IOF command including any parms. In */   
/* this example there are no parms. */               
/* trace ?A */                                       
 push "IOF *.%"                                     
 /* TSICOPY NAME(JOBNAME) FROM(DIALOG) TO(REXX)     
 say 'jobname..' JOBNAME */                         
 JOBNAME = "JTAIN92.IOF.PARM"                       
 TSICOPY NAME(JOBNAME) FROM(DIALOG) TO(REXX) ROW(01)
 exit                                               
 /* exit the initial exec */ end                     
/* If IOF environment, process IOF subcommands */   
else do                                   
say 'i am in IOf'                         
 address IOF                             
exit end                                 
ERR:                                     
  SIGNAL OFF SYNTAX                       
  DROPBUF                                 
  SAY "ERROR ROUTINE OUTPUT STARTING"     
  SAY "   "                               
  SAY RIGHT(SIGL,6) ">>>" SOURCELINE(SIGL)
  SAY "   "                               


error message got is:

Code:

Rshanu2b 00000100 is now - Loopy PART2.0PART3.0
ERROR ROUTINE OUTPUT STARTING                   
16 >>>  TSICOPY NAME(JOBNAME) FROM(DIALOG) TO(REXX) ROW(01)
Back to top
View user's profile Send private message
steve-myers

Active Member


Joined: 30 Nov 2013
Posts: 917
Location: The Universe

PostPosted: Mon Feb 05, 2018 9:32 pm
Reply with quote

I cannot help you. I do not have access to IOF and it has been roughly 20 years since I used IOF. I just happened to look through the thread and observed the mixture of what appeared to be CLIST anf Rexx. I do have a generally favorable opinion about IOF based on my long ago use of it, but that's all I can say about it.
Back to top
View user's profile Send private message
Nic Clouston

Global Moderator


Joined: 10 May 2007
Posts: 2455
Location: Hampshire, UK

PostPosted: Mon Feb 05, 2018 9:33 pm
Reply with quote

Quote:
Rshanu2b 00000100 is now - Loopy PART2.0PART3.0

If this is the result of a SAY instruction then you are not showing all the code - and what precedes this is wrong otherwise PART2.0PART3.0 would surely have some real value.

Your first line of a program written in Rexx should be a comment containing the word "Rexx" - any case.
Back to top
View user's profile Send private message
prino

Senior Member


Joined: 07 Feb 2009
Posts: 1306
Location: Vilnius, Lithuania

PostPosted: Mon Feb 05, 2018 9:41 pm
Reply with quote

What was
Code:
TSICOPY NAME(JOBNAME) FROM(DIALOG) TO(CLIST) ROW(01)

is now
Code:
TSICOPY NAME(JOBNAME) FROM(DIALOG) TO(REXX) ROW(01)

Sheesh...

and the TS/OP is a Cognizant Project Manager.

'nuff said.
Back to top
View user's profile Send private message
Nic Clouston

Global Moderator


Joined: 10 May 2007
Posts: 2455
Location: Hampshire, UK

PostPosted: Tue Feb 06, 2018 6:47 pm
Reply with quote

You continue to post on other forums. Locked.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   This topic is locked: you cannot edit posts or make replies. View Bookmarks
All times are GMT + 6 Hours
Forum Index -> CLIST & REXX

 


Similar Topics
Topic Forum Replies
No new posts Running REXX through JOB CLIST & REXX 13
No new posts Error to read log with rexx CLIST & REXX 11
No new posts isfline didnt work in rexx at z/OS ve... CLIST & REXX 7
No new posts run rexx code with jcl CLIST & REXX 15
No new posts Execute secondary panel of sdsf with ... CLIST & REXX 1
Search our Forums:

Back to Top