The SAS Output Delivery System and reporting techniques

Error using ODS

Accepted Solution Solved
Reply
Super Contributor
Posts: 254
Accepted Solution

Error using ODS

When I submit the following code, I get this error: 

ERROR: A component of C:\Users\gbibb\AppData\Local\Temp\SAS Temporary

       Files\_TD3472_DO-GBIBB-LT2_\G:\Departments\Research\MAP\1415\Longitudinal Match\Spring to

       Spring\math_long_match_by_Spr14_ELEMschool.xls is not a directory.

ERROR: No body file. HTML output will not be created.

HOWEVER, when I submit the same code a 2nd time, it works fine.  Is SAS creating a directory on the first submit that allows it to work on the second submit?

Code:

proc sort data=map2;

by school;

run;

ODS html body='G:\Departments\Research\MAP\1415\Longitudinal Match\Spring to Spring\math_long_match_by_Spr14_ELEMschool.xls';

proc tabulate data=MAP2;

by school;

where grade_s14 ne '' and grade_s13 ne '' and grade_s12 ne '' and grade_s14 not in ('10','11','12','9','8','7','6');

class grade_s14 grade_s13 grade_s12 Math_Met_SS_1314 Math_Met_SS_1213;

table grade_s12*grade_s13*grade_s14, Math_Met_SS_1213*(n*f=6.0 pctn<Math_Met_SS_1213>='PCT'*f=6.1) Math_Met_SS_1314*(n*f=6.0 pctn<Math_Met_SS_1314>='PCT'*f=6.1) / rts=25 box=_page_condense;

title'math results';

run;

ods html close;


Accepted Solutions
Solution
‎02-19-2015 10:42 AM
Grand Advisor
Posts: 9,748

Re: Error using ODS

I've seen this happen and is a combination of preferences using the work folder for default output. The referenced

C:\Users\gbibb\AppData\Local\Temp\SAS Temporary

       Files\_TD3472_DO-GBIBB-LT2_\

part of the error was very likely the location of the WORK library.

If I recall correctly HTML output works better with a Path="G:\Departments\Research\MAP\1415\Longitudinal Match\Spring to Spring" Body="math_long_match_by_Spr14_ELEMschool.xls" reference.

And since you apparently actually want Excel output you might use ODS tagsets.Excelxp and create Excel readable xml files.


View solution in original post


All Replies
Solution
‎02-19-2015 10:42 AM
Grand Advisor
Posts: 9,748

Re: Error using ODS

I've seen this happen and is a combination of preferences using the work folder for default output. The referenced

C:\Users\gbibb\AppData\Local\Temp\SAS Temporary

       Files\_TD3472_DO-GBIBB-LT2_\

part of the error was very likely the location of the WORK library.

If I recall correctly HTML output works better with a Path="G:\Departments\Research\MAP\1415\Longitudinal Match\Spring to Spring" Body="math_long_match_by_Spr14_ELEMschool.xls" reference.

And since you apparently actually want Excel output you might use ODS tagsets.Excelxp and create Excel readable xml files.


Super Contributor
Posts: 254

Re: Error using ODS

Thanks.  You actually touched on the real problem -- I need to learn more about using tagsets.  I've done some reading on them but haven't gotten a handle on it.  Any readings you can suggest would be greatly appreciated.

Gregg

Grand Advisor
Posts: 9,748

Re: Error using ODS

I suspect if you search this forum for "tagsets.excelxp" you will find more than enough examples (right and wrong) to get started.

Post a Question
Discussion Stats
  • 3 replies
  • 441 views
  • 0 likes
  • 2 in conversation