The SAS Output Delivery System and reporting techniques

Displaying a summarized SAS data table?

Reply
Contributor
Posts: 38

Displaying a summarized SAS data table?

 

/*Hi Forum,

I have this dataset.

*/

data have;

input product income;

cards;

1 1000 15000

1 5000 25000

2 590 1000

3 777 500

3 777 800

3 243 987

;

run;

 

/*And I summarized it using proc sql code below.*/

 

proc sql;

create table smry as

select product

,count(*) as acct_ct

,sum(income) as spot_income format = dollar20.

from have

group by 1;

quit;

 

/*SQL generates the below small SAS data resutls table. I have over 80 such summarized tables. I do not want to export them to Excel

and present.*/

productacct_ctspot_income
12$6,000
21$590
33$1,797

 

/*Q: Is there any method to display the above SAS data resutls table just like proc tablulate, proc freq etc. display. Any help is appreciated. Proc tabulate alternative would not be the answer, I want to display the SAS tables

*/

 

Super User
Posts: 20,688

Re: Displaying a summarized SAS data table?

It's really unclear what you're asking here. You don't want to export them to Excel? You want a proc to display the results like tabulate/freq? What about PROC PRINT or REPORT?
Super User
Super User
Posts: 8,349

Re: Displaying a summarized SAS data table?

Sorry, not understanding what the quesiton is?  If you don't want output files (e.g. Excel) then you would view datasets by opening them in the datasets view?

Super User
Posts: 11,765

Re: Displaying a summarized SAS data table?

If you don't use a create table statement in that code the results of the select go directly to the open ODS destination.

By default that would be the SAS results viewer but an ODS destination could write to an RTF or PDF or other file type as desired.

Ask a Question
Discussion stats
  • 3 replies
  • 97 views
  • 0 likes
  • 4 in conversation