fixed selectivity index bug