Informix Indexes
Posted in 1991
Hello, I have a question regarding a limitation on indexes that I read in the INFORMIX-4GL 4.0 Users Guide. The text from the guide is a follows... . Do not index columns that contain a large number of duplicate values, such as Y (for yes) or N (for no). Here the index can significantly slow down the process of accessing values in the indexed column. Moreover, you cannot have more than 65,536 occurrences of the same value in an indexed column-an important consideration when designing a large database. Well, I understand the logic of the first two sentences, but I have a problem with the third... Moreover, you cannot have more than 65,536 occurrences of the same value in an indexed column-an important consideration when designing a large database. Say if I have a table with a column that may contain one of 10 values, and there will certainly be more than 65,536 occurrences of one/some/all of the possible values in that column. My planned index on this table would have this column as the last part of a composite index. According to the above statement, this is not recommended. But, if the index is a composite index, (which mine is) I don't see how the above statement applies. My rationale is this: by the time the query processor gets to the last part of this index the number of occurrences of the same value in the column will be much less than 65,536. Therefore, there shouldn't be a problem? ...right? I'm I missing something... Do I not understand how the query processor works... Is the above excerpt from the guide a typo... Any ideas, suggestions, or actual experience with a similar dilemma will be greatly appreciated. Thank You, Tom Leccese Performance Software Inc. voice: (201)-808-7062 email: uunet!4gen!psi!tom