sql - MySQL - How to add index to certain column? -


how add index column?

alter table table_name add index (column_name) alter table table_name add key (column_name) 

which 1 correct? , can explain differences between them?

in mysql documentation alter table, can find:

| add {index|key} [index_name]         [index_type] (index_col_name,...) [index_option] ... 

it's not stated explicitly, index , key synonyms in context. there no differences between them.


Comments

Popular posts from this blog

SPSS keyboard combination alters encoding -

Add new record to the table by click on the button in Microsoft Access -

javascript - jQuery .height() return 0 when visible but non-0 when hidden -