BookmarkSubscribeRSS Feed
Quentin
Super User

Hi,

If I write a stored process that uses a (non-pooled) workspace server, the server actually starts a new session to run the process, right?

Is there a way I can define SAS invocation options for the stored process (-altlog -autoexec -config etc?).  I want to define these at the stored process level (so, e.g. different stored processes might use different autoexecs), not at the server level.  I'm developing stored processes, but I don't administer the server.

One approach would be to use systask to kick off a new SAS session (with the desired options), as Scott Bass describes:

https://communities.sas.com/thread/34901

But was wondering if I could define in the stored process metada (and/or as a prompt) the system options to be specified during invocation.

Thanks,

--Q.

The Boston Area SAS Users Group (BASUG) is hosting our in person SAS Blowout on Oct 18!
This full-day event in Cambridge, Mass features four presenters from SAS, presenting on a range of SAS 9 programming topics. Pre-registration by Oct 15 is required.
Full details and registration info at https://www.basug.org/events.
2 REPLIES 2
shivas
Pyrite | Level 9

Hi ,

Try this link...it may give some idea...

http://support.sas.com/kb/32/231.html

For individual stored processes , add the custom SASAUTOS path by adding the path in an OPTIONS statement that is specified at the beginning of the stored process code. For example:

OPTIONS SASAUTOS=("c:\myautocalls\dir" "SASEnvironment/sasMacro" SASAUTOS)

Quentin
Super User

Thanks,

SASAUTOS can be defined in the actual stored process code.  And that is what I'm doing now:

  options insert=(sasautos="/myautocalls/dir");

But lots of system options (ALTLOG, AUTOEXEC, CONFIG) can only be specified during invocation.  Seems that when a new SAS process is invoked to run a stored process, it would be nice to be able to define (in the metadata associated with the stored process), the system options that should be set during the invocation.

But I guess we can't do that yet.  Maybe I'll propose this to the SASware ballot.

Thanks,

-Q.


The Boston Area SAS Users Group (BASUG) is hosting our in person SAS Blowout on Oct 18!
This full-day event in Cambridge, Mass features four presenters from SAS, presenting on a range of SAS 9 programming topics. Pre-registration by Oct 15 is required.
Full details and registration info at https://www.basug.org/events.

SAS Innovate 2025: Call for Content

Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!

Submit your idea!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 2 replies
  • 1066 views
  • 0 likes
  • 2 in conversation