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

I'm having trouble outputting a proc print table to my desktop. We have a SAS EG v6.1 license installed on a server.

 

I'm receiving the following error:

 

ERROR: Insufficient authorization to access C:\HH_Providers.pdf

 

 

when I run my code:

 

ods pdf file="C:\HH_Providers.pdf";

PROC PRINT DATA=WORK.SORTTempTableSorted style(header)={just=c}

NOOBS

LABEL

;

VAR SVC_QTR MEMBNO MEMB_NAME HH_NAME SVC_PROVIDER SVC_DATE DIAG_IND / style(data)={just=c};

BY SVC HH_NAME;

FORMAT

SVC_DATE MMDDYYS8.;

LABEL SVC_QTR="# of Qualifying Visits/Episodes"

MEMBNO="Member Number"

MEMB_NAME="Member Name"

HH_NAME="Home Health Provider"

SVC_PROVIDER="Healthcare Provider"

SVC_DATE="Visit/Episode Date"

DIAG_IND="Diagnosis Indicator";

RUN;

ods _all_ close;

 

1 ACCEPTED SOLUTION

Accepted Solutions
BrunoMueller
SAS Super FREQ

Hi

As already mentioned the SAS Server can not see your local drives. However Enterprise Guide has the functionality to download results to your local computer. Follow the steps below.

 

  • In the properties of your code within Enterprise Guide, you can specify the output format you want like HTML, PDF etc.
  • when you run the code you will get an icon in your processflow representing the result.
  • Using your RightMouseButton on the result choose Export as step in project. This will allow you to download the result from the SAS server to your local computer.

 

Bruno

View solution in original post

7 REPLIES 7
JuanS_OCS
Amethyst | Level 16

Try writing the pdf to a different location than c:, as in a folder where you have permissions.

Generally Windows protects to write directly on c: 

RobF
Quartz | Level 8

I tried writing to my H: drive, still no luck:

 

ERROR: Physical file does not exist, H:\HH_Providers.pdf.

 

The weird thing is that I *can* export datasets to my desktop from EG using the Export wizard. But not when using ods statements to output files from a procedure.

 

Reeza
Super User

The server can't see your C or H drive. 

 

You our need to figure where it can see and where you can create files - most likely a path on the server. 

Kurt_Bremser
Super User

Your situation will look like this:

 

 

Desktop   ---------  H:  --------->   File Server

    |                                              X

    |                                              X

 via EG                                      H: mount on the SAS server does not exist, but would be needed

    |                                              X

    |                                              X

   V                                             X

SAS server ---------------------------------

CaseySmith
SAS Employee

Remember, the paths specified in code are from the context of the server.  So, when you specify "C:\HH_Providers.pdf" in your code, SAS is trying to write that file on the SAS server's host machine.  The user that you are logged into EG as is evidently not authorized to access "c:\" on the server.


Register today and join us virtually on June 16!
sasglobalforum.com | #SASGF

View now: on-demand content for SAS users

BrunoMueller
SAS Super FREQ

Hi

As already mentioned the SAS Server can not see your local drives. However Enterprise Guide has the functionality to download results to your local computer. Follow the steps below.

 

  • In the properties of your code within Enterprise Guide, you can specify the output format you want like HTML, PDF etc.
  • when you run the code you will get an icon in your processflow representing the result.
  • Using your RightMouseButton on the result choose Export as step in project. This will allow you to download the result from the SAS server to your local computer.

 

Bruno

RobF
Quartz | Level 8

Thank you Bruno - this is the best workaround solution for now.

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

Register now!

SAS Enterprise Guide vs. SAS Studio

What’s the difference between SAS Enterprise Guide and SAS Studio? How are they similar? Just ask SAS’ Danny Modlin.

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
  • 7 replies
  • 3885 views
  • 3 likes
  • 6 in conversation