Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

How to pass parms to SAS from REXX.

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> All Other Mainframe Topics
View previous topic :: :: View next topic  
Author Message
vasanthz

Global Moderator


Joined: 28 Aug 2007
Posts: 1505
Location: Chennai

PostPosted: Fri Sep 23, 2011 1:02 pm    Post subject: How to pass parms to SAS from REXX.
Reply with quote

Hi,
Could you please let me know how to pass parms to SAS, when SAS is called by a REXX program.
I use the below code to call SAS from REXX,
Code:
 ADDRESS TSO "ALTLIB ACTIVATE APPL(CLIST) DA('WELLS.CLIST.CEXEC')"
"%SAS INPUT('''WELLS.SAS.PROG''') LOG('''WELLS.SAS.LOG''')"

The PDS WELLS.CLIST.CEXEC contains a member named SAS.
And this memeber is the standard CLIST supplied by SAS to invoke SAS from REXX or CLIST.
The program inside WELLS.SAS.PROG gets executed fine, but don't know how to pass parms to the program. Please help.

Thanks & Regards,
Back to top
View user's profile Send private message

Bill Woodger

DFSORT Moderator


Joined: 09 Mar 2011
Posts: 7315

PostPosted: Fri Sep 23, 2011 1:43 pm    Post subject: Reply to: How to pass parms to SAS from REXX.
Reply with quote

Whilst waiting for a reply I'd not be able to resist just having a whack at PARM(...)
Back to top
View user's profile Send private message
vasanthz

Global Moderator


Joined: 28 Aug 2007
Posts: 1505
Location: Chennai

PostPosted: Fri Sep 23, 2011 2:18 pm    Post subject:
Reply with quote

Hello Bill,
I did try tagging the PARM keyword before posting,
Tried,
Code:
"%SAS INPUT('''WELLS.SORTIN''') ,                         
      LOG('''WELLS.SAS.LOG''') PARM('''SYSPARM="HELLO"''')"

The error was:
Code:
IKJ56701I MISSING SPACE VALUE AND IF ANY, INCREMENT VALUE+   
IKJ56716I EXTRANEOUS INFORMATION WAS IGNORED: 'SYSPARM=HELLO'
IKJ56701I MISSING NUMBER OF RECORDS

The same error appeared for other variations of argument inside PARM().
The "SAS companion ZOS" has some information about SASPARM= PGMPARM= but they sound greek and latin to me :S

Regards,
Back to top
View user's profile Send private message
superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 4649
Location: Raleigh, NC, USA

PostPosted: Fri Sep 23, 2011 11:25 pm    Post subject: Reply to: How to pass parms to SAS from REXX.
Reply with quote

This code worked for me:

Code:

/* REXX */                                 
"SAS INPUT(sas) OPT('SYSPARM=HELLO')"       
Exit 0                                     


Code:

%PUT &SYSPARM;   
RUN;             
Back to top
View user's profile Send private message
vasanthz

Global Moderator


Joined: 28 Aug 2007
Posts: 1505
Location: Chennai

PostPosted: Mon Sep 26, 2011 12:37 pm    Post subject:
Reply with quote

Thanks Kevin,
Works Great!!

Could you please let me know the link which has information on the statement, or is it based on your earlier experiences.
(can't find it on the companion for ZOS)
Back to top
View user's profile Send private message
superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 4649
Location: Raleigh, NC, USA

PostPosted: Thu Sep 29, 2011 1:15 am    Post subject: Reply to: How to pass parms to SAS from REXX.
Reply with quote

I think it might've been this site:

http://www.lexjansen.com/pharmasug/2002/proceed/coders/cc05.pdf
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 -> All Other Mainframe Topics All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts REXX to get the all datasets name parasmalik20 CLIST & REXX 5 Tue Jul 18, 2017 9:10 pm
No new posts How system know which REXX to excute? jackzhang75 CLIST & REXX 14 Thu Jul 06, 2017 1:09 am
No new posts REXX - Dynamic file Creation d_sarlie CLIST & REXX 7 Tue Jun 27, 2017 7:30 pm
No new posts REXX WTO for console message bipinpeter CLIST & REXX 6 Tue Jun 27, 2017 3:56 pm
No new posts Convert CLIST to REXX cvnlynn CLIST & REXX 12 Tue Jun 27, 2017 2:06 am


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us