Hi Team,
I need help to download file in FTP server with password, im trying but is not working.
Full FTP link example: ftponline.zipcode.com/file/d/files/file.zip
My code:
filename teste ftp 'file.zip'
cd='file/d/files/'
host='ftponline.zipcode.com'
user='SAS_HELP'
pass='XXX'
passive binary recfm=s;
data _null_;
infile teste;
input;
put _infile_;
run;
Log:
ERROR: Open failed for file TESTE
ERROR: Connection refused.
NOTE: The SAS System stopped processing this step because of errors.
NOTE: DATA statement used (Total process time):
real time 13.13 seconds
user cpu time 0.01 seconds
system cpu time 0.01 seconds
memory 770.46k
OS Memory 18848.00k
Timestamp 10/28/2019 10:52:57 AM
Step Count 8 Switch Count 44
Page Faults 0
Page Reclaims 364
Page Swaps 0
Voluntary Context Switches 175
Involuntary Context Switches 5
Block Input Operations 0
Block Output Operations 0
anyone knows what i need to do?
Thanks in advanced!!!
First of all, test if an ftp connection to the server works from your SAS environment.
If you use remote, server-based SAS, log on to the SAS server with your SAS user-ID and run ftp from the commandline. Otherwise, test the ftp connection from your desktop.
Also note that you most probably have to use an absolute path for the change directory:
/file/d/files
April 27 – 30 | Gaylord Texan | Grapevine, Texas
Walk in ready to learn. Walk out ready to deliver. This is the data and AI conference you can't afford to miss.
Register now and lock in 2025 pricing—just $495!
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.
Ready to level-up your skills? Choose your own adventure.