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
 
ISPF batch not running - error for any Address ISREDIT comd.

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> TSO/ISPF
View previous topic :: :: View next topic  
Author Message
vd120

New User


Joined: 06 Nov 2010
Posts: 24
Location: NYC

PostPosted: Mon Nov 08, 2010 9:56 pm    Post subject: ISPF batch not running - error for any Address ISREDIT comd.
Reply with quote

Hi!

I'm trying to run edit macros in ISPF batch and receive RC=20 on any command right after Address ISREDIT.
This is macro:
/*REXX*/
X = LISTDSI(FILE01 FILE)
trace ?I
IF X = 0 THEN
DO
Address ISREDIT
"MACRO"
"EDIT DATASET('"SYSDSNAME"')"
"X 'SOURCE' ALL"
"delete NX ALL"
"SAVE"
"END"
end
else
say 'File name invalid'

exit

This is displays on SDSF:
READY
PROFILE PREFIX(RMD0142)
READY
ISPSTART CMD(%TEMP) NEWAPPL(ISR)
4 *-* IF X = 0
>V> "0"
>L> "0"
>O> "1"
IRX0100I +++ Interactive trace. TRACE OFF
*-* THEN
5 *-* DO
6 *-* Address ISREDIT
7 *-* "MACRO PROCESS"
>L> "MACRO PROCESS"
+++ RC(20) +++
8 *-* If rc = 0
>V> "20"
>L> "0"

Any command after receives same RC=20.
What I'm doing wrong?
Back to top
View user's profile Send private message

Akatsukami

Global Moderator


Joined: 03 Oct 2009
Posts: 1777
Location: Bloomington, IL

PostPosted: Mon Nov 08, 2010 10:02 pm    Post subject:
Reply with quote

I believe that the EDIT command is properly addressed to ISPF, not the Edit service itself,and would therefore be coded as:
Code:

address ispexec "EDIT DATASET('" || sysdsname || "') MACRO(macro_name)"
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 Nov 08, 2010 10:05 pm    Post subject: Reply to: ISPF batch not running - error for any Address ISR
Reply with quote

I'm confused.

If the dataset exists (checked by the LISTDSI function), then you call an ISPF Edit Service, but you haven't shown where you pass it the name of the ISPF Edit Macro.
Back to top
View user's profile Send private message
vd120

New User


Joined: 06 Nov 2010
Posts: 24
Location: NYC

PostPosted: Mon Nov 08, 2010 10:11 pm    Post subject:
Reply with quote

Superk,

This is probably where one of my problems is. I was under impression that once I issue "EDIT DATASET('"SYSDSNAME"')" command the rest of commands (Find, exclude....) will be issued against this dataset. But why I received RC=20 on MACRO? This is before I issue EDIT command.
Back to top
View user's profile Send private message
vd120

New User


Joined: 06 Nov 2010
Posts: 24
Location: NYC

PostPosted: Mon Nov 08, 2010 10:23 pm    Post subject:
Reply with quote

Akatsukami,

you were right, once I change my code per your instruction it works!

Thank you.
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 -> TSO/ISPF All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts IEW2456E error when link-editing a C ... Senthilraj JCL & VSAM 0 Fri Oct 13, 2017 3:12 pm
No new posts Accessing CICS tran with map from JCL... navdeepaggarwal CICS 5 Tue Oct 03, 2017 6:15 pm
No new posts FTP Skip or ignore error and process ... AJAYREDDY All Other Mainframe Topics 3 Wed Sep 27, 2017 8:12 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 Assembler Macro Copybook converted to... Ziquilix PL/I & Assembler 4 Tue Sep 26, 2017 3:07 am

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