BookmarkSubscribeRSS Feed
Obsidian | Level 7
We are not allowed in our company to use the SAS portal, but we were in need of a presentation layer for reports.

We made a stored process that read's out the metadata server to display the available stored processes and made a some code to make parameter selections available.

We call the stored process with the line below:

This gives us a nice presentation of the available stored processes. The only problem is that it does not display the stored processes for which the users are authorised. It display's the stored processes for the account that is allowed to execute the stored process on the sas server.

Is it possible to read out the metadata rights for the user who log's on to the webinterface? We know it's is possible to read out the metadata but than you need the userid and password and offcourse we don't know the password.
Rhodochrosite | Level 12
What release of SAS are you using?

Will using _ACTION=index work for you?


The servlet will list only stored processes that the authenticated is allowed to "see".

Vince DelGobbo
Obsidian | Level 7
We are using SAS 9.1.3 Service Pack 4.

We know about _action=index but that does not work for us. First of all if you click on a stored process you get a second screen we don't want that and we use some special code to make a selection screen.

It would be nice if we could see how the code behind _action=index works, and than in particular how to show only the information for which the user is authorized.

http://server:port/SASStoredProcess/do?_action=index the code behind this is java I think or am I wrong.
Rhodochrosite | Level 12

In SAS 9.2 you will have a connection to the metadata server under the correct identity (whoever you logged in as). Thus it seems your code will run properly under this release.

Do you have plans to migrate to 9.2?

The SAS Stored Process Web Application is written in Java, and the logic to create the index and property pages is self-contained. If you can program in Java, you can create a JSP page to replace the logic you are now doing in SAS.

One other option is to try running your code on a workspace server. I believe you will have a connection to the metadata server under the correct identity.

When you register the stored process, select "Transient package" for the output type. Then you will have to make some modifications to your code. I assumed that your stored process writes HTML to _WEBOUT. Here is some test code based on that assumption.



%let _ODSDEST=html;


ods html close;

* Replace the file named "main.html" in the STP work directory;

filename _webout "&_STPWORK.main.html";

data _null_;
file _webout;
* Your SAS code here ;
put '<h3>Hello World</h3>';


Vince DelGobbo


Calcite | Level 5
@ Vince,

When the code is running in a Workspace Server, there is no session available in which temporary data can be stored, like the library 'save' when using the Stored Process Server.

So what is best thing to do?
1. Keep the program running in a Stored Process Server. But then we need to know a way to display only those items for which the user is authorized. How do you do that? You need to know groupmembership and all that. Seems very complex, timeconsuming, etc. ...
2. Run the program in a Workspace Server. But what is the best way to store temporary data like you do when using the Stored Process Server. Keeping a file in the home-directory of the user or something?

Regards, Raoul. Message was edited by: Raoul



Registration is open! SAS is returning to Vegas for an AI and analytics experience like no other! Whether you're an executive, manager, end user or SAS partner, SAS Innovate is designed for everyone on your team. Register for just $495 by 12/31/2023.

If you are interested in speaking, there is still time to submit a session idea. More details are posted on the website. 

Register now!

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.

Get the $99 certification deal.jpg



Back in the Classroom!

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

View all other training opportunities.

Discussion stats
  • 4 replies
  • 3 in conversation