I was given three data sets in .data format. Is it possible to import these into SS without converting them first?
Thank you!
Excel will probably transform the data. Better to just write a simple data step to dump a few records to the log.
data _null_;
infile 'myfile.data' obs=5 ;
input;
list;
run;
Are these files text or some sort of binary format?
If could post a few rows of the data in a code box opened using the forum's {i} menu icon we may be able to provide examples of what ot look for in the way of options.
If the data is in a proprietary data format such as some program uses it may be tricky but many text based file formats aren't much of an issue.
I believe its text. When I open it in a newer version of excel it gives me the options of creating spaces between the data and when you do that it looks like this:
Excel will probably transform the data. Better to just write a simple data step to dump a few records to the log.
data _null_;
infile 'myfile.data' obs=5 ;
input;
list;
run;
If you had to indicate where to break the values the data might be fixed column, in which case if you have a description document for the file SAS can read it fairly easily.
Or possibly delimited with tab, comma or similar character separating the values, which SAS cal also.
I would be very careful letting Excel hand a file as under a number of cases the value of cells saved in Excel can be different than intended.
I have seen Excel turn account numbers such as 123-456 into either arithmetic results or dates depending on the values of the numbers.
Join us for SAS Innovate 2025, our biggest and most exciting global event of the year, in Orlando, FL, from May 6-9. Sign up by March 14 for just $795.
Need to connect to databases in SAS Viya? SAS’ David Ghan shows you two methods – via SAS/ACCESS LIBNAME and SAS Data Connector SASLIBS – in this video.
Find more tutorials on the SAS Users YouTube channel.