Hi im new to sas. I have a file with some charecter variables and some numeric variables
now i want to load charecter variables into one datastep and numeric variables into another data step pls let me know
Thanks

Answer Posted / chaudhary_1989

data a;
infile "C:Documents and SettingssasadmDesktopSASMacro est1.txt" firstobs=2;
input num1 num2 num3 c1$ c2$ num4 c3$;
run;

data b;
set a;
keep _numeric_;
run;

data c;
set a;
keep _character_;
run;

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the work of tranwrd function?

672


How do you control the number of observations and/or variables read or written? Approximately what date is represented by the SAS date value of 730?

1168


Which command is used to save logs in the external file?

572


What is your favorite all time computer book? Why?

2050


How do you use the do loop if you don’t know how many times you should execute the do loop?

755






Mention what is PROC in SAS?

605


Do you need to know if there are any missing values?

600


what can you learn from the sas log when debugging? : Sas programming

612


what is sas metadata server? : Sas-di

596


what is data access? : Sas-di

611


explain the concepts and capabilities of business object? : Sas-bi

545


Explain substr function?

580


If a variable contains only numbers, can it be a character data type?

616


explain about various caches available in data integrator? : Sas-di

584


explain the main difference between the nodup and nodupkey options? : Sas-administrator

694