> The oddity in the calculation is a consequence of the limits on character-based histograms, see particularly:
http://jonathanlewis.wordpress.com/2010/10/13/frequency-histogram-5/
http://jonathanlewis.wordpress.com/2010/10/19/frequency-histograms-6/
Looking at the example, the query is for an IN list, not for a single row, so my initial guess would be that the optimizer has used a generic strategy for calculating multi-row selectivity rather than having a special case piece of code for an IN list on a primary key. I guess it wouldn't be too hard for them to recognise this case, but the de…