[ Dolphin logo ] Richard Wallman - a MySQL® DBA (database administrator)

Skip menu

February 26, 2008

How to calculate cardinality

Filed under: Indexes and Indexing — richard @ 8:41 pm

When deciding whether to create a new index, or to split a table, it’s useful to work out the cardinality of the data to see whether it’s worth doing. It’s possible to calculate the cardinality of the data in a column before creating an index. (more…)

February 22, 2008

Indexes considered harmful

Filed under: Indexes and Indexing, Query Optimisation — richard @ 3:26 pm

The knee-jerk reaction to poor query performance is ‘Create an index!’, but this is not always guaranteed to improve query performance, and in some cases can even damage it. (more…)

What is cardinality?

Filed under: Back to Basics, Indexes and Indexing — richard @ 9:14 am

Cardinality refers to how many unique values a particular column contains with respect to the number of rows in that table. (more…)

©2008 Richard Wallman. Articles powered by WordPress
MySQL is a registered trademark of MySQL AB in the United States, the European Union and other countries.
Linux® is the registered trademark of Linus Torvalds in the U.S. and other countries. Valid XHTML 1.0 Strict