1

我收到了一个 .sas7bdat 文件,其文件名在扩展名前有 36 个字符。除了重命名文件之外,还有什么方法可以让 SAS 使用它?我试过options validvarname=extend了,但我不认为这是答案:

11         options validvarname=extend;
                ____________
                14
ERROR 14-12: Invalid option value extend for SAS option VALIDVARNAME.

我在 Windows 7 上使用 SAS 9.3。

4

1 回答 1

2
VALIDVARNAME=V7 | UPCASE | ANY

与变量名称相关,而不是数据集名称。

尽管

options VALIDMEMNAME=EXTEND;

指数据集,但只允许名称中包含特殊字符,限制仍然是 32 个字符。

来自 SAS 帮助:

> EXTEND
> specifies that a SAS data set name, a SAS data view name, or an item store name must follow these rules:
> Names can include national characters.
> The name can include special characters, except for the / \ * ? " < > |: -. characters.  
> Note: The SPD Engine does not allow ‘.’ (the period) anywhere in the member name.
> The name must contain at least one character.
> The length of the name can be up to 32 bytes.
> Null bytes are not allowed.
> Names cannot begin with a blank or a ‘.’ (the period).

所以我认为你必须重命名文件。

于 2013-10-25T13:16:47.553 回答