I'm quite new in MySQL and databases, I've just discovered and tried out indexes and something is not clear. I checked this question and the answers about cardinality and as I understood the value of cardinality represents the unique objects in the indexed column. Am I right? Or it's just an approximate value?
I'm asking this because I have a table with 40.000
rows, one of it's indexed column, call it column1
has 49
unique values, however it's cardinality has a value of 102. How is that possible? I tried to add new rows with totally unique values for the column1
, but the cardinality value haven't changed. Is it normal?