Using the ignore_dup_row and allow_dup_row options  Using the on segment_name option

Chapter 12: Creating Indexes on Tables

Using the sorted_data option

The sorted_data option of create index speeds creation of an index when the data in the table is already in sorted order, for example, when you have used bcp to copy data that has already been sorted into an empty table. The speed increase becomes significant on large tables and increases to several times faster in tables larger than 1GB.

If sorted_data is specified but data is not in sorted order, an error message displays and the command is aborted.

This option speeds indexing only for clustered indexes or unique nonclustered indexes. Creating a nonunique nonclustered index is, however, successful unless there are rows with duplicate keys. If there are rows with duplicate keys, an error message displays and the command is aborted.

Certain other create index options require a sort even if sorted_data is specified. See the create index description in the Reference Manual.





Copyright © 2005. Sybase Inc. All rights reserved. Using the on segment_name option

View this book as PDF