Indexing with function-based indexes  Using the unique option

Chapter 12: Creating Indexes on Tables

Syntax changes

The syntax for creating function-based indexes contains some new variables, shown in bold font:

 create [unique] [clustered] | nonclustered] index index_name
 on [[ database.] owner.] table_name
 (column_expression [asc | desc] [, column_expression [asc | desc]]...

Before you can execute create index you must turn the database option select into ON.

sp_dboption <dbname>, 'select into', true

Other changes in commands, stored procedures, and system tables necessary to creating function-based indexes are documented in “Computed columns and function-based indexes syntax changes”. All these are documented in the Reference Manual.





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

View this book as PDF