1

我正在尝试使用 SAS 9.2 创建 XPORT 文件。其中一个标签长度超过 40 个字符,并在PROC COPY.

我已经尝试过PROC COPYDATA创建XPORT文件。这有可能解决还是我不走运?

333        /* Export Dataset */
334        OPTIONS VALIDVARNAME=ANY;
335        /*
336        PROC COPY IN=work OUT=xptout MEMTYPE=data;
337         SELECT MyDataSet;
338        RUN;
339        */

NOTE: PROCEDURE DATASETS used (Total process time):
      real time           0.42 seconds
      cpu time            0.25 seconds


340        DATA xptout.MyDataSet;
341         SET work.MyDataSet;
342        RUN;

NOTE: The variable label {long label} has been truncated to {truncated label}.
NOTE: There were NNN observations read from the data set WORK.MyDataSet.
NOTE: The data set XPTOUT.MyDataSet has NNN observations and NN variables.
NOTE: DATA statement used (Total process time):
      real time           0.12 seconds
      cpu time            0.09 seconds
4

1 回答 1

2

多么可悲,但这是不可能的。XPORT格式是基于 80 个字符块的字节压缩格式。标签的 XPORT 变量描述中有 40 个字符的硬性限制。因此,虽然该列在 SAS 数据集中自身支持 256 个字符,但 XPORT 文件仅支持 40

:o(

于 2012-06-12T20:24:05.563 回答