I have been trying for a while now to ONLY get the output dataset from the proc tabulate procedure. Please note that I can get it exactly how I want it, but there is an html file output that comes along (which I don't want).
So, is there a way I can cancel that table output to only get the resulting dataset?
It's best to share any related SAS code you are executing for this type of question/post -- also it is even better if you were to share actual SAS log (pasted in your post or reply-post) to show any SAS-generated diagnostic messages.
Are you by any chance using SAS Enterprise Guide? If so, the creation of HTML output is turned on by default and there's a Tools --> Options choice (inside EG) to turn off HTML output file creation.
If you are NOT using SAS EG, but are instead using SAS Display Manager to submit code, then investigate whether you have automatic HTML file creation turned on by checking this path from the Display Manager pull down menus:
Tools --> Options --> Preferences --> Results tab
make sure that the choice "Create HTML" (in the middle of the window) is UNchecked....because if it is CHECKED, then HTML file creation is automatic.
You did not say whether you were using the OUT= option or ODS OUTPUT to create the output dataset. In either case, putting ODS LISTING CLOSE; before the PROC TABULATE step will cause the LISTING window output to be suppressed.
I'm sorry about the lack of information in my last post.
1) I am using SAS EG (Entreprise Guide)
2) I am using the OUT= option to get my output dataset
I know I can uncheck the html output option for my SAS, but other people from my department will use the program and I don't want them to get the html output as it is unnecessary and ressource consuming.
Note : I have tried putting the ODS LISTING CLOSE as well as the ODS HTML CLOSE command, but the html output poped up anyway.
Here is a bit of my code (note that to get the base code, I copied the SAS given code from the Summary Table option in SAS EG.)
Again, thank you for your time and patience.
ODS HTML CLOSE;
OUT=WORK.SummaryTable1(LABEL="Summary Tables for WORK.FINAL")
instead. If that does not work, you may need to work with Tech Support to get the automatic HTML file suppressed. I thought that EG opened the HTML destination without any ID= option, but if the report is popping up in HTML anyway, that must not be the case. Closing everything with the _ALL_ should work.
I am having a similar problem with a macro in EG, basically my macro uses proc univariate and proc freq along with ods ouput to generate some tables. After some manipulation I use a simple proc print to display my results.
I don't want to display the Univariate and freq outputs so at the top of my macro I have an ODS _ALL_ CLOSE;
The above works fine, the issue appears when further down in my macro I need to print out a table using Proc Print;
I have tried using the
The Listing displays the result but I get nothing in HTML.
Well, there is really more than one method for opening an ODS file. There's the simple:
ODS HTML FILE='myfile.html';
method of opening an HTML file. The above method of opening the file, needs to be closed with the simple: ODS HTML CLOSE;
However, there's a more advanced way of opening an ODS HTML file:
ODS HTML(ID=1) file='myfile1.html';
ODS HTML(FIRST) file='myfile_alt.html';
...what's in parentheses is called the ID= suboption. As you can see, it allows for great flexibility in naming the specific ODS destination that you're invoking to create your output file and the rule is that when you use this method you have to close the ODS file the same way you open it. So for the above methods of opening the file, the relevant closing methods would be:
ODS HTML(ID=1) CLOSE; and
ODS HTML(FIRST) CLOSE; OR
ODS _ALL_ CLOSE;
Enterprise Guide must open ODS HTML using the ID= suboption to keep it from accidentally being closed by someone who copied code that had an ODS HTML CLOSE in it. In your case, the _ALL_ was what you needed.