Reputation: 1354
MySQL (Innodb) uses inverted indexing or forward indexing ?
From article What's the difference between an inverted index and a plain old index?
, what I understand is whenever I get record from key (like and string, int), it is inverted indexing. Taking "inverted indexing" in this way means mySQL uses inverted indexing.
But then why mySQL uses term "index" in place of "inverted index"?
Upvotes: 6
Views: 1870
Reputation: 53870
I'm assuming InnoDB.
MySQL uses inverted indexes for its FULL TEXT indexes.
However, a standard clustered or secondary index are neither inverted or forward indexes. I don't know if there is a standard term for their architecture. Perhaps it's the plain old index or dense index. For each table record, there is one index entry.
As mentioned previously in comments, MySQL uses a B-Tree format by default.
MySQL does not yet (v5.6) support descending order indexes. E.g. when using the DESC
keyword for sorting, MySQL may simply traverse the index backwards.
Upvotes: 4