Mysql indexes
Inside a table:
INDEX(indexed_column)
Multiple Column Index
INDEX(indexed_column, indexed_column2)
Add Index to a table
ALTER TABLE table_name ADD INDEX(indexed_column)
Show Indexes:
SHOW INDEXES FROM table_name;
Remove Index
ALTER TABLE table_name DROP INDEX index_name;
Inside a table:
INDEX(indexed_column)
Multiple Column Index
INDEX(indexed_column, indexed_column2)
Add Index to a table
ALTER TABLE table_name ADD INDEX(indexed_column)
Show Indexes:
SHOW INDEXES FROM table_name;
Remove Index
ALTER TABLE table_name DROP INDEX index_name;
Comments
Post a Comment