if reading an external file to produce an external file, what
is the shortcut to write that record without coding every
single variable on the record

Answers were Sorted based on User's Feedback



if reading an external file to produce an external file, what is the shortcut to write that record..

Answer / pratik

proc import
datafile='D:\Dropbox\SAS\testfile1.txt'
out=data_imported dbms=dlm replace;
getnames=NO;
run;

proc export
data=data_imported
outfile='D:\Dropbox\SAS\testfile2.txt' replace;
run;

Is This Answer Correct ?    7 Yes 0 No

if reading an external file to produce an external file, what is the shortcut to write that record..

Answer / learning sas

FILENAME EXTERNAL1 'PATH';
FILENAME EXTERNAL2 'PATH';
Proc import DATAFILE=EXTERNAL1
OUT=XYZ REPLACE;
GETNAMES=YES;
RUN;
DATA _NULL_;
FILE EXTERNAL2;
SET XYZ;
PUT _ALL_;
RUN;

Is This Answer Correct ?    4 Yes 0 No

if reading an external file to produce an external file, what is the shortcut to write that record..

Answer / sas developer

DATA _NULL_; 
INFILE 'C:FILESINPUT.TXT' MISSOVER TRUNCOVER; 
INPUT BLOCK $100.; /* This is length of the record. Change to suit your file*/
FILE 'C:FILESOUTPUT.TXT';
PUT BLOCK;
RUN;

Is This Answer Correct ?    1 Yes 0 No

if reading an external file to produce an external file, what is the shortcut to write that record..

Answer / harshit

use proc export

Is This Answer Correct ?    1 Yes 5 No

Post New Answer

More SAS Interview Questions

Describe 5 ways to do a “table lookup” in SAS?

0 Answers  


How would you code the criteria to restrict the output to be produced?

9 Answers  


what is the difference between proc report and proc format?

7 Answers   CTS,


How to create a permanent sas data set?

0 Answers  


Identify statements whose placement in the DATA step is critical?

11 Answers  






Where do the database management systems store data and how do u import them.

2 Answers   L&T,


Explain append procedure?

0 Answers  


how would you determine the number of missing or nonmissing values in computations? : Sas programming

0 Answers  


what is sas enterprise intelligence architecture? : Sas-bi

0 Answers  


What is the one statement to set the criteria of data that can be coded in any step?

4 Answers   Accenture,


name few built in sas transformation in DI studio ?

4 Answers   SAS,


is QUALCOMM using SAS ?

1 Answers  


Categories