Hi,
I would like to stream output from a stored process to multiple excel files for multiple datasets.
I've tried this for one dataset: 40683 - Streaming output from a SAS® Stored Process to Microsoft Excel
This works fine for one dataset to one excel file.
Is it possible to do this in one stored process for multiple datasets to multiple excel files via the excel popup window?
Thanks in advance.
Regards,
Berry
Web browsers cannot handle downloading multiple files at once.
The MIME headers that are set using the STPSRV_HEADER function are sent to the Web browser before the data stream. The browser interprets the headers and then determines what to do with the data stream that follows. You cannot send multiple MIME headers between data streams, meaning in your case, you can only open a single output stream using Excel. This is standard HTTP behavior and is not an issue with SAS.
Vince DelGobbo
SAS R&D
Web browsers cannot handle downloading multiple files at once.
The MIME headers that are set using the STPSRV_HEADER function are sent to the Web browser before the data stream. The browser interprets the headers and then determines what to do with the data stream that follows. You cannot send multiple MIME headers between data streams, meaning in your case, you can only open a single output stream using Excel. This is standard HTTP behavior and is not an issue with SAS.
Vince DelGobbo
SAS R&D
Thank you.
Very clear answer.
Regards,
Berry
You can create multiple Excel reports in one stored process request and return an HTML page that uses the replay program to allow the user to download the files one at a time.
Here is the doc to the replay program:
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.
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.