BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
bheerschop
Obsidian | Level 7

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

1 ACCEPTED SOLUTION

Accepted Solutions
Vince_SAS
Rhodochrosite | Level 12

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

View solution in original post

3 REPLIES 3
Vince_SAS
Rhodochrosite | Level 12

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

bheerschop
Obsidian | Level 7

Thank you.

Very clear answer.

Regards,

Berry

DonH
Lapis Lazuli | Level 10

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:

SAS/IntrNet(R) 9.2: Application Dispatcher - Replay Program 

sas-innovate-2024.png

Available on demand!

Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.

 

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.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

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

View all other training opportunities.

Discussion stats
  • 3 replies
  • 2131 views
  • 0 likes
  • 3 in conversation