Getting dataset name

IBM's Command List programming language & Restructured Extended Executor
User avatar
MrSpock
Global moderator
Posts: 809
Joined: Wed Jun 06, 2007 9:37 pm
Skillset: REXX, JCL, DFSORT, Syncsort, Axway MFT, Connect:Direct, FTP, SFTP
Referer: ibmmainframes.com
Location: Raleigh NC USA
Contact:

Re: Getting dataset name

Postby MrSpock » Fri Sep 21, 2007 7:32 pm

Jeri Kattar wrote:Hi,
Can anyone help me in this regards.


Are you going to post the output from your TRACE like I asked for earlier?

Jeri Kattar
Posts: 10
Joined: Wed Sep 19, 2007 6:37 pm
Skillset: COBOL, JCL, DB2
Referer: Website

Re: Getting dataset name

Postby Jeri Kattar » Tue Sep 25, 2007 7:13 pm

Hi,
This is the output I get, when I execute the above code.


MEM

User avatar
MrSpock
Global moderator
Posts: 809
Joined: Wed Jun 06, 2007 9:37 pm
Skillset: REXX, JCL, DFSORT, Syncsort, Axway MFT, Connect:Direct, FTP, SFTP
Referer: ibmmainframes.com
Location: Raleigh NC USA
Contact:

Re: Getting dataset name

Postby MrSpock » Tue Sep 25, 2007 11:37 pm

This is my macro code:

Code: Select all

/* REXX */                     
TRACE I                         
ADDRESS ISREDIT                 
"ISREDIT MACRO"                 
"ISREDIT (MEM) = DATASET"       
SAY MEM                         


This is the output when it runs:

Code: Select all

     3 *-* ADDRESS ISREDIT                   
     4 *-* "ISREDIT MACRO"                   
       >L>   "ISREDIT MACRO"                 
     5 *-* "ISREDIT (MEM) = DATASET"         
       >L>   "ISREDIT (MEM) = DATASET"       
     6 *-* SAY MEM                           
       >V>   "MRSPOCK.REXX"                   
MRSPOCK.REXX                                 
***                                           

Jeri Kattar
Posts: 10
Joined: Wed Sep 19, 2007 6:37 pm
Skillset: COBOL, JCL, DB2
Referer: Website

Re: Getting dataset name

Postby Jeri Kattar » Wed Sep 26, 2007 12:32 pm

Hi,
This is the trace obtained, when I executed the code. Return code of 20 is encountered.

Code: Select all

      3 *-* ADDRESS ISREDIT
      4 *-* "ISREDIT MACRO"
        >L>   "ISREDIT MACRO"
        +++ RC(20) +++
      5 *-* "ISREDIT (MEM) = DATASET"
        >L>   "ISREDIT (MEM) = DATASET"
        +++ RC(20) +++
      6 *-* SAY MEM
        >L>   "MEM"
 MEM
 ***

User avatar
marso
Posts: 12
Joined: Mon Jul 30, 2007 5:04 pm

Re: Getting dataset name

Postby marso » Wed Sep 26, 2007 9:57 pm

Start with /* REXX */
ISREDIT MACRO must be the 1st statement in the macro, so remove the ADDRESS ISREDIT.

User avatar
MrSpock
Global moderator
Posts: 809
Joined: Wed Jun 06, 2007 9:37 pm
Skillset: REXX, JCL, DFSORT, Syncsort, Axway MFT, Connect:Direct, FTP, SFTP
Referer: ibmmainframes.com
Location: Raleigh NC USA
Contact:

Re: Getting dataset name

Postby MrSpock » Thu Sep 27, 2007 5:34 pm

After 15 posts, we're finally getting to where we should've been from the first post. The RC=20 is indicative of a major failure.

The only things I can think of:

1. ISPF is not active or not available.
2. The macro is not being called from an ISPF EDIT/VIEW session.

Jeri Kattar, I think it's time for you to get in touch with your System Admin team and have them look into this issue. There isn't, and hasn't, been anything wrong with your code.

User avatar
dick scherrer
Global moderator
Posts: 6268
Joined: Sat Jun 09, 2007 8:58 am

Re: Getting dataset name

Postby dick scherrer » Mon Oct 01, 2007 11:07 pm

Hwello,

Have you run with trace?

The output from a trace may help.
Hope this helps,
d.sch.