4 ms·
It depends. In MySQL, if the only columns you select are indexed columns, the entire query will be pulled from the index, which is usually entirely in-memory, s
by seldo 15y ago
It depends. In MySQL, if the only columns you select are indexed columns, the entire query will be pulled from the index, which is usually entirely in-memory, so enormously faster:
http://dev.mysql.com/doc/refman/5.5/en/where-optimizations.html http://dev.mysql.com/doc/refman/5.5/en/where-optimizations.h...
(The columns currently all have to be numeric for this to be true, but that's surprisingly often the case)