Archives of the TeradataForum
Message Posted: Fri, 22 Nov 2002 @ 19:52:41 GMT
Where you'e got a composite index but some queries only specify one of the columns you could try the HASH ORDERED index option.
Syntax is: CREATE INDEX (col1, col2, col3...) ON TABLE t1 ORDER BY HASH (col1);
This gives you a composite index which contains data values from multiple columns (hence the index may be used to cover some queries) but is hash ordered by a single column. This last fact means that the index may be used when the query only specifies an equality constraint on that single column (col1 in this example).
Of course, if some queries use an equality constraint on col2 or col3 then the above won't help you....
Ward Analytics Ltd: Information in motion (www.ward-analytics.com)
|Copyright 2016 - All Rights Reserved|
|Last Modified: 28 Jun 2020|