Your SAS programs, embedded in web apps and elsewhere

Web Stored Process Path and Program Parameterization Via Management Console

Reply
Contributor
Posts: 62

Web Stored Process Path and Program Parameterization Via Management Console

Is it possible via Management Console to define a stored process parameter for the program path and name when the web stored process utilizes a custom jsp input page? I would like to utilize a parameterized value to reduce maintenance overhead by taking the currently hardcoded values out of the jsp page and have them reside in Management Console.

Have included an example below that shows the jsp being used in the development environment and the programmer or server administrator has to remember to change this value when promoting a project to either test or production environments. Realize that this seems like a minor thing but it is easy to overlook when one is fighting dealines.

Many Thanks!!!!

---- Begin Example Code ---



SAS Super FREQ
Posts: 306

Re: Web Stored Process Path and Program Parameterization Via Management Console

If you define a text-based parameter named "PROGRAM2" you could write some Java code to use that parameter value in the custom JSP page, instead of a hard-coded value. But if I understand your question, I think you are moving the hard-coding from the JSP page to the stored process definition. Is that what you want?

Vince DelGobbo
SAS R&D
Contributor
Posts: 62

Re: Web Stored Process Path and Program Parameterization Via Management Console

You are correct. The content on my BI Server is order into three distinct folders: Development, Test and Production. It is very easy to promote content from one folder to another with the exception of web stored processes that utilize jsp pages to handle custom input parameters. In the current usage situation, it is necessary for us to modify the value that is hardcoded in the jsp to reflect the revised directory/program path. Ideally, we would like to define a stored process parameter in Management Console that is used to pass the correct path to the jsp. Is this feasible?
SAS Super FREQ
Posts: 306

Re: Web Stored Process Path and Program Parameterization Via Management Console

Which version of SAS are you running, SAS 9.1.3 or SAS 9.2?

Vince DelGobbo
SAS R&D
Contributor
Posts: 62

Re: Web Stored Process Path and Program Parameterization Via Management Console

SAS 9.2
SAS Super FREQ
Posts: 306

Re: Web Stored Process Path and Program Parameterization Via Management Console

You may not have to add a parameter to the stored process, but instead, use the reserved "parameter" _PROGRAM. Here is some sample code that works in SAS 9.1.3 and SAS 9.2. Simply replace the hard-coded value for _PROGRAM:
[pre]
">
[/pre]

Give this a try to see if it meets your needs.

Vince DelGobbo
SAS R&D
Ask a Question
Discussion stats
  • 5 replies
  • 269 views
  • 0 likes
  • 2 in conversation