I have a strange situation. An InnoDB table with a couple million rows. A distinct on one of the columns was always yielding 0. With some binary search I found that it is the case then the id is smaller than 500,000 ? What's that all about?
mysql> select count(distinct theme_author) from url_item where id < 499999; +------------------------------+ | count(distinct theme_author) | +------------------------------+ | 36493 | +------------------------------+ 1 row in set (0.44 sec) mysql> select count(distinct theme_author) from url_item where id < 500000; +------------------------------+ | count(distinct theme_author) | +------------------------------+ | 0 | +------------------------------+ 1 row in set (0.44 sec) mysql> select version(); +-----------+ | version() | +-----------+ | 5.6.12 | +-----------+