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
 
Reg: Clist STATUS command...

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CLIST & REXX
View previous topic :: :: View next topic  
Author Message
karthikr44

Active User


Joined: 25 Aug 2007
Posts: 235
Location: Chennai

PostPosted: Thu Apr 02, 2009 12:52 pm    Post subject: Reg: Clist STATUS command...
Reply with quote

Hi,

Clist code:
Code:

CLRCRT     
WRITE WHO'S ON               
WRITENR BALA     ==>       
STATUS C3E4TR               
WRITENR DEENA    ==>       
STATUS C3E55R               


Current o/p:
Code:

BALA      ==>  IKJ56192I JOB C3E4TR(T0055666) ON OUTPUT QUEUE   
IKJ56192I JOB C3E4TR(T0061140) ON OUTPUT QUEUE                 
IKJ56192I JOB C3E4TR(T0061998) ON OUTPUT QUEUE                 
IKJ56192I JOB C3E4TR(T0069705) ON OUTPUT QUEUE                 
IKJ56211I JOB C3E4TR(T0070146) EXECUTING                       

DEENA     ==>  IKJ56192I JOB C3E55R(T0064453) ON OUTPUT QUEUE                 


Expected o/p:
Code:

BALA      ==>  IKJ56211I JOB C3E4TR(T0070146) EXECUTING                           


Here i want to know only the users who are all active i.e only the batch jobs in EXECUTING status. But when i use the STATUS command, it also displays the jobs which is on o/p queue.

Please share ur thoughts...

Thanks in advance
R KARTHIK
Back to top
View user's profile Send private message

expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8597
Location: Back in jolly old England

PostPosted: Thu Apr 02, 2009 3:19 pm    Post subject:
Reply with quote

STATUS shows the status so if the job has finished its status will be ON OUTPUT QUEUE
Back to top
View user's profile Send private message
karthikr44

Active User


Joined: 25 Aug 2007
Posts: 235
Location: Chennai

PostPosted: Thu Apr 02, 2009 4:23 pm    Post subject: Reply to: Reg: Clist STATUS command...
Reply with quote

Hi expat,

Ya u are correct. But is there any way to display only the job currently in EXECUTING status. I dont want to display the jobs which are held in queue.

Regards
R KARTHIK
Back to top
View user's profile Send private message
Pedro

Senior Member


Joined: 01 Sep 2006
Posts: 2088
Location: Silicon Valley

PostPosted: Fri Apr 03, 2009 12:24 am    Post subject: Reply to: Reg: Clist STATUS command...
Reply with quote

Why CLIST? REXX is recommended.


Use OUTTRAP to capture the command response, examine the response, and SAY the ones you are interested.
Back to top
View user's profile Send private message
karthikr44

Active User


Joined: 25 Aug 2007
Posts: 235
Location: Chennai

PostPosted: Fri Apr 03, 2009 1:58 pm    Post subject: Reply to: Reg: Clist STATUS command...
Reply with quote

Hi,

I got it using the following code.

Code:

/* REXX */
USER.0=4                       
USER.1="C0ER95 ANDYS    "       
USER.2="C0ER87 MARGUE    "       
USER.3="C0ER17 SHANKAR  "       
USER.4="C4ER86 BENDY     "           
"CLRCRT"                         
DMY=OUTTRAP("OTPTLINES.","*")   
"STATUS C0ER95"                 
"STATUS C0ER87"                                     
"STATUS C0ER17"                                     
"STATUS C4ER86"                                     
NUMLINES=OTPTLINES.0                               
DMY = OUTTRAP("OFF")                               
DO I = 1 TO NUMLINES                               
  IF POS("EXECUTING",OTPTLINES.I) > 0 THEN DO       
    PARSE VAR OTPTLINES.I  . "JOB " USRID "(" .     
   DO J = 1 TO USER.0                                 
     IF COMPARE(SUBSTR(USER.J,1,6),USRID) = 0 THEN DO 
       USERNAME = SUBSTR(USER.J,8,9)                   
       LEAVE                                           
     END                                               
     ELSE                                             
       USERNAME = "USER NOT FOUND"                     
   END                                                 
   SAY USERNAME " ====> " OTPTLINES.I                 
  END                                                 
END   


Thanks expat and pedro...
R KARTHIK
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 -> CLIST & REXX All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts OUTREC with ALter Command scorp_rahul23 DFSORT/ICETOOL 1 Wed Nov 22, 2017 3:10 pm
No new posts MQ command in option 6 of ISPF! Vignesh Sid All Other Mainframe Topics 3 Tue Sep 26, 2017 6:01 pm
No new posts How to change a string containing the... chong.zhou TSO/ISPF 6 Tue Aug 29, 2017 4:54 pm
No new posts Failure after DIR command Hank Watson All Other Mainframe Topics 2 Tue Aug 29, 2017 3:14 am
No new posts Command to find TMEMBER name for a TPIPE Siva NKK Kothamasu IMS DB/DC 0 Wed Aug 16, 2017 6:08 pm

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