I have a unique non-clustered index on a sybase table which includes 4 columns: col1, col2, col3 and col4.
I want to drop one of the columns from the table.
I don't want to drop and recreate the i开发者_运维技巧ndex.
Can I alter the index to not consider this column?
Shortly no.
You can only alter "database", "role" or "table" in sybase. With using "alter table" you can modify only columns.
Adding or removing a column to index causes an index to be re-created. Sybase doesn't like "modify" something if it has to be re-created so you have to drop and create the index.
精彩评论