1) Transient package -- can be created on either Workspace Server or Stored Process Server. These results are a "package", generally of mixed result types that can come back to a client application for rendering. These results are generally put into a temporary cache location on the client machine and rendered or displayed by the client application.
2) Permanent package -- can be created on either Workspace Server or Stored Process Server. These results are a "package" -- a SAS package file -- that can be written, permanently, to a server file location OR to a webDAV repository (like Xythos).
3) Streaming results -- can only be created on Stored Process Server -- these results are most like the HTTP protocol results that could be returned with the SAS/IntrNet Application Dispatcher program.
For example, you could possibly put a SAS dataset into a permanent package along with a PDF file of a report and possibly an HTML version of the same report. However, in the "streaming" world, you would not send all 3 disparate files down an HTTP pipeline. With streaming results, only one type of content comes down the pipeline at a time -- because of the HTTP request/response model:
user makes a request --> request is fulfilled with streaming HTML results
user makes a second request --> request is fulfilled with a PDF binary file (and the right content-type header for the content)
The Stored Process developer's guide does go into more detail, as do our training classes, on the subject of developing stored processes and stored process result types. Generally, the stored process developer decides on the result type based on what the stored process needs to return. For example, if I had a stored process that was only producing a report -- a tabular report -- I'd pick STREAMING as the result type and execute the SP on the Stored Process server. On the other hand, if I had a stored process that was a tabular report AND a graph, then I'd pick TRANSIENT as the result type and execute the SP on either of the servers -- because the streaming result type isn't appropriate for "mixed" content like a table and an image.
Keep in mind that if you writing your own custom front end to execute stored processes, then you must consult the documentation for Java or .NET or ... in order to find out how to handle stored process results in those applications that you write.
(PS...there is also a result type of NONE -- which would be used for a stored process whose only purpose in executing was to create data files or some non--report--output purpose.)
Thanks for such a beautiful and educative reply.
Just a small question to know what would you suggest.
1. A report having PROC REPORT code, text file using FILENAME statement, ODS CSV to create CSV. This is actually a scheduled report and will bew viewed in Stored Process Application only for testing purpose.
Since this is mixed content (Proc REPORT output, CSV file, TXT file), I'd recommend using TRANSIENT output type -- either the Stored Process Server or Workspace Server will create transient output.
When you submit a Stored Process that returns transient results -- and has multiple output files in the transient package -- when the SP executes using the Stored Process Web Application, the transient package comes back to a temporary internet cache file and what displays on the browser screen is an HTML frame with the different outputs in a navigation area on the left.
When you click on the HTML output, the HTML file shows in the browser. When you click on the CSV output, if the CSV filetype is registered to Excel on your system, then the browser would launch Excel to open the CSV file. If the CSV filetype is NOT registered to Excel, then I think the file will open in the browser, as text. When you click on the TXT file, the file shows in a notepad-ish viewer inside the browser.
(Of course, if your transient package just has one result -- like 1 proc report output -- then you would not see the frame.)
The code below modifies the example code to use PROC REPORT, CSV and DATA _NULL_ only. There is another syntax for sending output to packages using DATA step CALLS. For more information on that method, you would have to read the documentation or consult with Tech Support.
*************************** code **********************************
/* This stored process creates multiple files and inserts */
/* them in the result package */