|Date: ||Fri, 18 Feb 2000 14:36:23 -0500|
|Reply-To: ||"Powers, Tonya" <PowersT@MEDIMMUNE.COM>|
|Sender: ||"SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>|
|From: ||"Powers, Tonya" <PowersT@MEDIMMUNE.COM>|
|Subject: ||Re: CGI and SAS to perform similar functions of SAS/IntrNet?|
|Content-Type: ||text/plain; charset="iso-8859-1"|
Does anyone know of any SAS programming jobs in the DC metro area?
From: David L. Ward [mailto:dward@SASHELP.COM]
Sent: Thursday, February 17, 2000 1:08 PM
Subject: Re: CGI and SAS to perform similar functions of SAS/IntrNet?
I'm developing a web-based application using SAS/SCL as the backend
processing and perl to pass requests from the internet to a SAS server (on a
different machine than the Web server).
I have what I call a "SAS dispatcher" running on the SAS server, which acts
as a tcp/ip server via the SOCKET access method in the filename statement,
waiting for connections from the web server. The dispatcher listens on a
particular port, and serves to provide a log in entry point. When a user
with the proper credentials logs in, the dipspatcher opens another SAS
session on the SAS server, listening on another port, and sends back a
cookie to the user that tells the browser which port his/her session is on.
Once the cookie is sent, the perl script can send the requests to the
session instead of the dispatcher.
One particular problem I faced was how to manage open sessions and kill them
if they had gone for a certain amount of time with no activity. The SAS
SOCKET server method has no timeout, so the only way to kill a session is to
send it a command to do so. The solution was to create another SAS session,
called the "killer" to monitor the sessions and how long is had been since
the last request on each one, and send a kill message if it had been too
The process is certainly complicated but the net effect is quite nice. We
have the potential to set up a SAS "server" inside of a corporate firewall
and give the web server access to it via TCP/IP only, which can be
controlled by the firewall. Additionally, the web server can be almost any
kind and does not have to have SAS installed on it.
One other interesting note is that I was able to send binary images created
by SAS/Graph to the web server, then ultimately the client by specifying the
correct HTTP headers and sending the data from SAS in recfm=F mode.
Hope this creates some ideas,
From: Jeffrey A. Jordan <jeff-jordan@TAMU.EDU>
Sent: 2/16/00 11:37:34 PM
Subject: CGI and SAS to perform similar functions of SAS/IntrNet?
> I am interested in anyone's experience with using CGI scripts from a
>webserver on a different machine than the SAS server. Ideally, I would
>to pass parameters to a SAS program on a remote server (perhaps through
>and have SAS run the program and return the results to the web browser. We
>are running the webserver on a Linux box (Apache) and the SAS server on a
>Sun Sparc box. We are trying to use Perl with CGI.pm, but we also have php
>installed if anyone has experience with these. Sample code would be very
>much appreciated. Thanks for any help.
Sent by SASHelp.com user DWard
SASHelp.com - On-Line SAS Resources
Web interface to SAS-L at http://www.sashelp.com/sasl