BookmarkSubscribeRSS Feed
rajeshalwayswel
Pyrite | Level 9

How to import large number of variables from excel sheet above 256 variables . Variables range in excel sheet range ah:gg100 .

 

I'm getting error as name "xx" is too long for sas name in this context.

4 REPLIES 4
Reeza
Super User
Convert it to CSV is the fastest method. You can do that manually or there's a script on here somewhere that can automate that if necessary. It's VBS though, so you would need permissions to run it.
ballardw
Super User

Is it an actual ERROR or a WARNING that a name has been truncated? There is a difference. SAS has a limit of 32 characters for a variable name. If your source file has more than 32 characters SAS has to do something which may involve truncating a name or if you have multiple variables with the same leading 32 (+) characters you may get a name of VAR plus the column number.

 

 

 

 

Reeza
Super User
Upon re-reading, your subject doesn't match your actual question. Or are you having both issues? The 256 limit depends on the engine being used (DBMS) and the xx too long, is the SAS limitation of 32 characters. That's usually a note that it will convert it though.

hackathon24-white-horiz.png

The 2025 SAS Hackathon has begun!

It's finally time to hack! Remember to visit the SAS Hacker's Hub regularly for news and updates.

Latest Updates

Mastering the WHERE Clause in PROC SQL

SAS' Charu Shankar shares her PROC SQL expertise by showing you how to master the WHERE clause using real winter weather data.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 4 replies
  • 1510 views
  • 0 likes
  • 4 in conversation