mirror of
https://github.com/FirebirdSQL/firebird.git
synced 2025-01-23 22:43:04 +01:00
Fixed optimizer bug introduced by me appr. one month ago.
This commit is contained in:
parent
df5a23d861
commit
20ce2e24d8
@ -6434,8 +6434,9 @@ static SSHORT sort_indices_by_priority(csb_repeat * csb_tail,
|
||||
regardless of their (probably old) selectivity values. */
|
||||
IDX *idx = idx_csb[last_idx];
|
||||
bool should_be_used = true;
|
||||
if (!(idx->idx_flags & idx_unique) && idx->idx_selectivity && !(csb_tail->csb_plan)) {
|
||||
if (selectivity * SELECTIVITY_THRESHOLD_FACTOR < idx->idx_selectivity) {
|
||||
if (idx->idx_selectivity && !(csb_tail->csb_plan)) {
|
||||
if (!(idx->idx_flags & idx_unique) &&
|
||||
selectivity * SELECTIVITY_THRESHOLD_FACTOR < idx->idx_selectivity) {
|
||||
should_be_used = false;
|
||||
}
|
||||
selectivity = idx->idx_selectivity;
|
||||
|
Loading…
Reference in New Issue
Block a user