sas9.3索引数据集的奇怪行为

时间:2015-06-19 10:23:28

标签: sas

我在SAS 9.3中编写以下查询:

CREATE TABLE XYZ AS
select count(distinct x) 
from sasdata.dsn (keep=x); 

sasdata.dsn作为复合索引在变量xy上建立索引。

有些奇怪的是,执行时的查询是在sastmp中创建索引的临时文件(如图所示)

-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21798912 Jun 19 03:18 sastmp-000000008.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21471232 Jun 19 03:18 sastmp-000000009.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21667840 Jun 19 03:19 sastmp-000000010.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21864448 Jun 19 03:20 sastmp-000000011.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21749760 Jun 19 03:21 sastmp-000000012.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21823488 Jun 19 03:22 sastmp-000000013.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21651456 Jun 19 03:23 sastmp-000000014.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21798912 Jun 19 03:25 sastmp-000000015.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21651456 Jun 19 03:27 sastmp-000000016.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21569536 Jun 19 03:29 sastmp-000000017.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21635072 Jun 19 03:31 sastmp-000000018.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21774336 Jun 19 03:33 sastmp-000000019.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21757952 Jun 19 03:36 sastmp-000000020.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21897216 Jun 19 03:38 sastmp-000000021.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21790720 Jun 19 03:41 sastmp-000000022.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21774336 Jun 19 03:44 sastmp-000000023.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21757952 Jun 19 03:48 sastmp-000000024.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21635072 Jun 19 03:51 sastmp-000000025.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21618688 Jun 19 03:55 sastmp-000000026.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21774336 Jun 19 03:58 sastmp-000000027.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21798912 Jun 19 04:02 sastmp-000000028.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21839872 Jun 19 04:06 sastmp-000000029.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21848064 Jun 19 04:11 sastmp-000000030.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21766144 Jun 19 04:15 sastmp-000000031.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21757952 Jun 19 04:20 sastmp-000000032.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21774336 Jun 19 04:25 sastmp-000000033.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21618688 Jun 19 04:30 sastmp-000000034.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21774336 Jun 19 04:35 sastmp-000000035.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21700608 Jun 19 04:40 sastmp-000000036.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21569536 Jun 19 04:46 sastmp-000000037.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21676032 Jun 19 04:51 sastmp-000000038.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 22077440 Jun 19 04:57 sastmp-000000039.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21839872 Jun 19 05:03 sastmp-000000040.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21725184 Jun 19 05:09 sastmp-000000041.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21577728 Jun 19 05:16 sastmp-000000042.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21749760 Jun 19 05:22 sastmp-000000043.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21643264 Jun 19 05:29 sastmp-000000044.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21258240 Jun 19 05:36 sastmp-000000045.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21594112 Jun 19 05:43 sastmp-000000046.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 22175744 Jun 19 05:50 sastmp-000000047.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21708800 Jun 19 05:58 sastmp-000000048.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21880832 Jun 19 06:05 sastmp-000000049.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 21700608 Jun 19 06:13 sastmp-000000050.sas7bndx.lck
-rw-rw-r-- 1 KROUSETLP UNIX_KROGER_DM 12836864 Jun 19 06:17 sastmp-000000051.sas7bndx.lck

这有什么理由吗?此外,性能非常差,所以您对如何快速获得复合索引中涉及的变量的明确计数有任何建议吗?

0 个答案:

没有答案