Help using Base SAS procedures

Proc Export on Mac via Terminal

Reply
Occasional Contributor
Posts: 5

Proc Export on Mac via Terminal

 

 

I am trying to export table on a remote server to my mac using

 

proc export data=mydata.table

    outfile ="\Users\Mine\Desktop\table.xlsx"

    dbms=xlsx

    replace;

run;

 

I keep on getting error, saying temporary file cannot be created. make sure the path name is correct and that you have write permission. Do I have to download the table in sas format on to my mac and then use proc export to convert into excel format? or is my directory wrong?

Community Manager
Posts: 2,772

Re: Proc Export on Mac via Terminal

Where is SAS running? On a remote machine (such as a Linux box)?  Or are you using SAS University Edition?

 

If the former, you have to export to a location on that remote box, then FTP the file to your local folders.  Remote SAS can't see your local file system.

 

If the latter, then you need to use the Shared Folder mechanism in the VirtualBox setup that is hosting your SAS and SAS Studio instance.  Plenty of doc about that in the SAS University Edition FAQs.

Super User
Posts: 6,972

Re: Proc Export on Mac via Terminal

If the SAS process is running on a server, it won't be able to access your Mac desktop.

How are you using SAS? Enterprise Guide, SAS Studio, Display Manager, batch mode?

---------------------------------------------------------------------------------------------
Maxims of Maximally Efficient SAS Programmers
Occasional Contributor
Posts: 5

Re: Proc Export on Mac via Terminal

I think I remotely access to a server and run emacs on that server to run sas. (I am SAS dummy, so I am not sure if this answers your question...) But I get that my mac is unable to recognize that table.
Super User
Posts: 6,972

Re: Proc Export on Mac via Terminal

You need to find a location on the server that you can write to. Then use a file transfer tool to retrieve the unloaded data to your Mac.

---------------------------------------------------------------------------------------------
Maxims of Maximally Efficient SAS Programmers
Occasional Contributor
Posts: 5

Re: Proc Export on Mac via Terminal

Yes, I think just writing those lines won't give me the file. Thank you Smiley Happy
Ask a Question
Discussion stats
  • 5 replies
  • 141 views
  • 0 likes
  • 3 in conversation