the complete guide to sas indexes

343 186 0
the complete guide to sas indexes

Đang tải... (xem toàn văn)

Tài liệu hạn chế xem trước, để xem đầy đủ mời bạn chọn Tải xuống

Thông tin tài liệu

[...]... Introduction to Indexes The Index Concept 2 The Index as a SAS Performance Tool 2 Types of SAS Applications That May Benefit from Indexes 4 How SAS Indexes Are Structured 4 Types of SAS Indexes 9 Simple Indexes 9 Composite Indexes 9 When Indexes Are Used 11 Estimating the Size of an Index 12 Summary 15 2 The Complete Guide to SAS Indexes The Index Concept The concept of an index is hardly new to us We use indexes. .. containing the key variable value of Barre SAS follows each RID, one by one, to the SAS data set and returns each of the three observations to the program When the last observation has been obtained, the SAS program is finished with the index search for Barre Chapter 1: Introduction to Indexes 9 Types of SAS Indexes SAS gives you the ability to construct two different types of indexes The difference... the number of pages for each index together to get the total index pages used by all indexes for the SAS data set You can stop there, or multiply total index pages by the index page size to get the total number of bytes for the entire index file The index size estimate program is a great tool for getting a reasonable estimate of the amount of space needed for your SAS indexes It is probably most useful... than if SAS reads the entire data set sequentially If your applications are extracting small subsets from large SAS data sets, then it is usually appropriate to create SAS indexes to improve 18 The Complete Guide to SAS Indexes the performance of those applications However, though it is a very important consideration, the size of the subset is not the only criteria for determining whether or not to create... specific SAS data set Before attempting to build a SAS index or to use one, you should determine whether an index will truly improve the efficiency of your application There are three main issues that influence the effectiveness of indexes: the size of the subset and the size of the SAS data set the frequency of use of the index the variability of the data All three of these issues must be examined to ensure... increases, the efficiency of using the index to read the data decreases There is a finite point at which the size of the subset becomes too large, relative to the size of the data set At this point, the overhead of using the index becomes greater than the overhead of a sequential read of the entire data set (This is due to the additional CPU time and I/Os consumed moving index pages from disk into the buffers... set is indexed, then the indexes must be rebuilt when the SAS data set is re-created This may consume a significant amount of computer resources depending on the size of the data set and the number of indexes that are created In order to make the resources spent building them worthwhile, the SAS indexes must be used often enough between the time they are created and the next time that the data set is... Conversely, the fewer I/Os your SAS program consumes, the quicker it runs So you can see that it is advantageous to limit the number of I/Os your SAS program uses, whenever possible The main goal of using a SAS index is to read only a small portion of a large SAS data set, instead of reading the entire SAS data set As with the book index example, above, you want to use the SAS data set index to reduce the. .. number into the number of RIDs on an index page This results in a decimal number that is less than or equal to one 12 The Complete Guide to SAS Indexes 3 Calculate the number of data pages that would be read by the index SAS multiplies the estimated number of qualified observations (#1 above) by the I/O cost per RID (#2 above) to get the number of SAS data set pages that would be read if the index... a SAS index returns the observations in sorted order They are sorted into ascending key variable(s) value order in your output SAS data set This eliminates the need to execute subsequent SORT procedures and enhances BY statement processing 4 The Complete Guide to SAS Indexes Types of SAS Applications That May Benefit from Indexes Just about any type of SAS application can benefit from the use of SAS . Raithel The Complete Guide to SAS ® Indexes The correct bibliographic citation for this manual is as follows: Raithel, Michael A. 2006. The Complete Guide to SAS ® Indexes. Cary, NC: SAS. SAS data set that has the value field value in it. SAS uses the RID to directly 6 The Complete Guide to SAS Indexes access the SAS data set and return the observation with the requested key variable. 4 The Complete Guide to SAS Indexes Types of SAS Applications That May Benefit from Indexes Just about any type of SAS application can benefit from the use of SAS indexes because of the

Ngày đăng: 01/06/2014, 12:28

Tài liệu cùng người dùng

Tài liệu liên quan