BookmarkSubscribeRSS Feed
Kamal5522
Obsidian | Level 7
As we know that we can not use special character in name of data set and variable etc because special character are used as operators so they are not allowed in name,however number can be used in name however name can not be started with number.
My question is why we can not start dataset and variable name with number, actually I want to know the logic behind it ?
2 REPLIES 2
Kurt_Bremser
Super User

The SAS interpreter and data step compiler treat every digit encountered after a separator (blank, comma, semicolon, linefeed etc) as the start of a number. The rules for names in the SAS language are very similar to other programming languages (eg C, PL/1, PASCAL) and aid compiler/interpreter design.

Ksharp
Super User

Maybe You could use dataset/variable name start with number.

Try this option.

 

options validmemname=extend validvarname=any;