2,187
edits
(→SHOW etc: Renamed to " Maintenance" and added "Corruption") |
m (→Keys / Indexes: Minor update) |
||
Line 141: | Line 141: | ||
=== Keys / Indexes === | === Keys / Indexes === | ||
There are three different types of indexing available for a table, all of which can be made against one or more columns in your table | There are three different types of indexing available for a table, all of which can be made against one or more columns in your table | ||
* '''Primary''' - compulsory, often on an <code>AUTO_INCREMENT</code> id | * '''Primary''' - compulsory, often on an <code>AUTO_INCREMENT</code> id. Must be unique for each row. | ||
* '''Unique''' - optional, useful to enforce uniqueness in a table | * '''Unique''' - optional, useful to enforce uniqueness in a table across columns not included in Primary Key | ||
* '''FullText''' - optional, used to create a full text index, which you can later do fuzzy searches against. | * '''FullText''' - optional, used to create a full text index, which you can later do fuzzy searches against. | ||
All keys have a name, if you don't specify one at creation, the name of the first column is used. | All keys have a name, if you don't specify one at creation, the name of the first column is used. | ||