BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
HeinzK
Calcite | Level 5

Hi,

I have a mix of SAS Stored Processes. Each of these Stored Processes has at least 1 or 2 prompts. Namely date ranges.

e.g.

SAS_STP1.sas [Prompt_StartDate, Prompt_EndDate]

SAS_STP2.sas [Prompt_StartDate, Prompt_EndDate]

SAS_STP3.sas [Prompt_Date]

Is it possible to write a SAS program, that uses these 3 different SAS stored processes? And how do I pass in parameters?

I was thinking something on the lines of:

%include corporate_libname.sas

libname stp1 '/models/storedprocesses/SAS_STP1.sas'

libname stp2 '/models/storedprocesses/SAS_STP2.sas'

libname stp3 '/models/storedprocesses/SAS_STP3.sas'

options symbolgen;

%MACRO testCode

DATA _NULL_;

stp1.Prompt_StartDate = '01JAN2013 00:00:00'dt

stp1.Prompt_EndDate  = '03JAN2013 00:00:00'dt

stp2.Prompt_StartDate = '01JAN2013 00:00:00'dt

stp2.Prompt_EndDate  = '03JAN2013 00:00:00'dt

stp3.Prompt_Date        = '01JAN2013 00:00:00'dt

stp1.run_macro;

stp2.run_macro;

stp3.run_macro;

RUN;

%MEND testCode

Any help on parameter passing to a SAS Stored Process would be great.

The method headers in each of the SAS Stored processes don't take in parameters, as they're handled by SAS prompts.

Cheers,

Henry

1 ACCEPTED SOLUTION

Accepted Solutions
1 REPLY 1

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

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
  • 1 reply
  • 679 views
  • 0 likes
  • 2 in conversation