Help using Base SAS procedures

Reading a mainframes file through SAS on Unix

Reply
Occasional Contributor
Posts: 5

Reading a mainframes file through SAS on Unix

Hi All,

I am trying to read a mianframes file through SAS but somehow the code is only reading the alternate lines of input data, Is there something I am missing out on.

Here's the SAS Code I have been trying :

FILENAME  FIXIT FTP "&FIXEDFILE"  host="dipe.ipc.us.xxxx.com"

          user="&mfuser." pass="&mfpass." cd='..' RECFM=F LRECL=200;

 

DATA FIXED;                         

   INFILE FIXIT ;           

   INPUT        

   @04  R_TRANCD $EBCDIC2.   

    @07  USERCD   $EBCDIC2.

   @20  TRANSAMT $EBCDIC14.

RUN;   

Could you please suggest.                              


SAS Employee
Posts: 20

Re: Reading a mainframes file through SAS on Unix

Do you get any warnings in the log?

Are you certain that RECFM=F and LRECL=200 are correct?

Regards,

Michael

Super User
Posts: 6,928

Re: Reading a mainframes file through SAS on Unix

What is the organisation of the file on the mainframe (FB, VB, ...) and the record size?

The log from the data step would be helpful.

Small hint:

filename fixit ftp "'&fixedfile'" .....;

lets you omit the cd='..' option. Note the single quotes inside the double quotes.

---------------------------------------------------------------------------------------------
Maxims of Maximally Efficient SAS Programmers
Ask a Question
Discussion stats
  • 2 replies
  • 228 views
  • 0 likes
  • 3 in conversation