Data visualization with SAS programming

Permissions issues on Unix/linux re: ODS graphics

Accepted Solution Solved
Reply
Frequent Contributor
Frequent Contributor
Posts: 139
Accepted Solution

Permissions issues on Unix/linux re: ODS graphics

Hello all- 

 

SO I have an issue where if I run something in batch or on a scheduler I get this error:

ERROR: Insufficient authorization to access /sharedsas/config/Lev1/NAApp/sasReport13.xml.

I am running an output that includes two graphs that export out to an Excel workbook. It works fine in the interactive enviroment but not in batch. I have attempted to redirect the xml  with an ODS XML Path statement but that does not seem to work-  

 

ods xml path="/apps/sas/datasets/data137/xxx/dev/nc_xxx_sandbox/data/dfrx/"; but that  seems to be not taking effect.

 

I was reading something about the display error and writing that to the shell script but that is something I do not have access to-

 

Thanks

 

Lawrence

 


Accepted Solutions
Solution
‎05-18-2017 01:04 PM
Frequent Contributor
Frequent Contributor
Posts: 139

Re: Permissions issues on Unix/linux re: ODS graphics

Ok to reply with my own solution per se-as a way to notify other users- 

 

So the issue was that I had originally used EG to build the template. Then I had swapped out  the Gchart for a SG Chart. 

But the template had inserted this statement into the code- 

 

ODS tagsets.sasreport13(ID=EGSR) gtitle. 

 

Once I had removed it the issue resolved itself.   

 

Anyway thanks for all the assistance. While it was not the solution this time, I am sure the answers will assist in the future.

 

LB 

View solution in original post


All Replies
SAS Super FREQ
Posts: 925

Re: Permissions issues on Unix/linux re: ODS graphics

I'm guessing a bit without seeing the code, but the destination you are using is probably not XML -- it's probably SASREPORT.  Try setting the path on ODS SASREPORT and see if that helps.

Frequent Contributor
Frequent Contributor
Posts: 139

Re: Permissions issues on Unix/linux re: ODS graphics

Dan; 

The export is xlsx. I just tried that by changing the path to 

ods SASREPORT path="/apps/sas/datasets/data137/xxx/dev/nc_xxx_sandbox/data/dfrx/";  and it still results in the same error- 

 

 

The bit of code I have is- 

options dev=PNG;
options center;
ods listing close;
ods escapechar="\";

ods SASREPORT path="/apps/sas/datasets/data137/xxx/dev/nc_xxx_sandbox/data/dfrx/";  

ods excel file="/apps/sas/datasets/data137/xxx/dev/nc_xxx_sandbox/data/dfrx/&&sitea&i.._MOBILITY_REPORT_&d1t..xlsx" style=Seaside options(sheet_name="MS STATISTICS" SHEET_INTERVAL= 'PAGE' autofilter='1' FROZEN_ROWHEADERS='no'
GRIDLINES='ON' embedded_titles='yes' embedded_footnotes='yes');

 

ODS _ALL_ Close;
ods listing;

 

In between that I have one proc report and two sgplot graph outputs. The graphs are the culprit. I have another report running sans graphs and that works just fine in batch mode. 

 

LB 

 

 

 

 

SAS Super FREQ
Posts: 925

Re: Permissions issues on Unix/linux re: ODS graphics

Just looking at the paths you've mentioned, this looks like a stored process. I believe that SASREPORT is opened by default for stored processes, but I don't think you care about that output. So, try adding this to the beginning of your program and see if it helps:

 

ods _all_ close;

 

Also, you might want to say:

 

ods graphics / outputfmt=png;

 

instead of:

 

options dev=png;

 

for your SGPLOT output.

 

Hope this helps!

Dan

Frequent Contributor
Frequent Contributor
Posts: 139

Re: Permissions issues on Unix/linux re: ODS graphics

Dan; 

 

Thanks for the suggestions-

Still get the errors. A little maddening.    

 

Lawrence 

 

 

Community Manager
Posts: 2,889

Re: Permissions issues on Unix/linux re: ODS graphics

On the ODS SASREPORT statement, try adding a gpath= option that points to a location where you can store files (can be the same as your output file destination).

Frequent Contributor
Frequent Contributor
Posts: 139

Re: Permissions issues on Unix/linux re: ODS graphics

Tried that too-that did not work but did find the issue. I will reply all to the issue-  

Super User
Posts: 11,121

Re: Permissions issues on Unix/linux re: ODS graphics

You may want to post the actual log for the excuted code shown.

Your first post has this path in the error:

/sharedsas/config/Lev1/NAApp/sasReport13

Your ods Excel shows

 

/apps/sas/datasets/data137/xxx/dev/nc_xxx_sandbox/data/dfrx/&&sitea&i.._MOBILITY_REPORT_&d1t..xlsx

and the same folder for ODS SASreport

 

 

Not the same paths.

 

Also with a statement like:

"The graphs are the culprit" you should show the code including the graphs and the log for the entire program.

 

By any chance are the graphs created by a non-SAS appication? Or a non-SG procedure such as Gplot or Gchart?

Frequent Contributor
Frequent Contributor
Posts: 139

Re: Permissions issues on Unix/linux re: ODS graphics

 

 

Solution
‎05-18-2017 01:04 PM
Frequent Contributor
Frequent Contributor
Posts: 139

Re: Permissions issues on Unix/linux re: ODS graphics

Ok to reply with my own solution per se-as a way to notify other users- 

 

So the issue was that I had originally used EG to build the template. Then I had swapped out  the Gchart for a SG Chart. 

But the template had inserted this statement into the code- 

 

ODS tagsets.sasreport13(ID=EGSR) gtitle. 

 

Once I had removed it the issue resolved itself.   

 

Anyway thanks for all the assistance. While it was not the solution this time, I am sure the answers will assist in the future.

 

LB 

☑ This topic is solved.

Need further help from the community? Please ask a new question.

Discussion stats
  • 9 replies
  • 280 views
  • 0 likes
  • 4 in conversation