DATA Step, Macro, Functions and more

FTP Error (The connection was reset by a peer..)

Reply
Occasional Contributor
Posts: 12

FTP Error (The connection was reset by a peer..)


Hi Guys,

I am trying to read a csv file from a winscp ftp server.

Filename in1 ftp "1203132345FILE1.prn" lrecl=32767 cd='a/b/c/folder' RECFM=V Host='xx.x.xxx.xx' user='user' pass='password'';

data temp;

  infile in1 delimiter=',' missover dsd recfm=v lrecl=32767;

  input a $1. b$2. so goes over 135 variables.;

run;

But in the log it says

ERROR: The connection was reset by a peer..

NOTE: The SAS System stopped processing this step because of errors.

But I was able to import the file when i got the file saved in one of my locations on network drive by using the following proc import.

proc import out=temp datafile="\\abc\xyz\1203132345FILE1.prn" dbms=csv replace; getnames=no;

run;

So the question is i dont understand why the filename ftp method is giving that error.

Help will be appreciated.

thanks

Eshan

Ask a Question
Discussion stats
  • 0 replies
  • 549 views
  • 0 likes
  • 1 in conversation