How do you download a flat file from Mainframe to your
local PC using SAS?
Answer Posted / paul
A flat file from mainframes generally have data values assigned with the variable names.
eg: cards;
name=XXX Age=XX Gender=XXXX
name=XXX Age=XX Gender=XXXX
name=XXX Age=XX Gender=XXXX
name=XXX Age=XX Gender=XXXX
;
so to read such data into SAS we simply use named input method.
data flat;
infile 'flatfile.csv';
input var1= $ var2= var3= :ddmmyy10. var4= ;
run;
/*here i specified var1 as char, var3 with date informat
rest are numeric vars */
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
How many data types are there in SAS?
How do you add a number to a macro variable? : sas-macro
What are the applications primarily used by business analyst? : Sas-bi
I have a dataset concat having a variable a b & c. How to rename a b to e & f?
what do the mod and int function do? What do the pad and dim functions do? : Sas programming
explain what is factor analysis? : Sas-administrator
For what purpose would you use the RETAIN statement?
how would you determine the number of missing or nonmissing values in computations? : Sas programming
How to test the debugging in sas?
what is information maps?
I have a dataset concat having variable a b & c. How to rename a b to e & f?
What do the put and input function do?
Explain append procedure?
Describe the ways in which you can create a macro variable?
how many types of prompts are there? : Sas-bi