DATA Step, Macro, Functions and more

Too many columns

Accepted Solution Solved
Reply
New Contributor
Posts: 2
Accepted Solution

Too many columns

Hi, I am relatively new to SAS University. I am trying to import an Excel spreadsheet that has >1000 columns. I imported the data successfully, but only the first 256 columns. My code is below:

 

libname in '/folders/myfolders/sas';
proc import datafile='/folders/myfolders/sas/Fibrosis.xls'
out=in.LVFibrosis
DBMS=xls
REPLACE;
run;

 

Am I limited by the software to 256 columns? And if so, does anyone have suggestions for working with a larger amount of data?

 

Thanks,


Accepted Solutions
Solution
‎02-19-2016 11:56 AM
Super User
Posts: 10,466

Re: Too many columns

I believe your issue lies with using XLS not XLSX. The older versions of Excel with extenstion XLS could not have more than 255 columns. So adjust your file name and and the engine.

 

 

View solution in original post


All Replies
Solution
‎02-19-2016 11:56 AM
Super User
Posts: 10,466

Re: Too many columns

I believe your issue lies with using XLS not XLSX. The older versions of Excel with extenstion XLS could not have more than 255 columns. So adjust your file name and and the engine.

 

 

New Contributor
Posts: 2

Re: Too many columns

Thanks a lot! That did the trick.

##- Please type your reply above this line. Simple formatting, no
attachments. -##
Super User
Posts: 17,750

Re: Too many columns

Please mark the question as answered, if you have a solution.

☑ This topic is SOLVED.

Need further help from the community? Please ask a new question.

Discussion stats
  • 3 replies
  • 244 views
  • 0 likes
  • 3 in conversation