MDEV-4687: impossible where with < operation, but =-5 return one row
- Let _ma_record_pos() set SEARCH_PART_KEY when doing a search on a prefix of a [unique] key. Otherwise, _ma_search_pos() would find the first key equal to search key, and assume it is also the last one, which will make a wrong estimate of key's position. A wrong key position may cause min_pos > max_pos and records_in_range() will return 0, which will make the optimizer think it's an impossible range while in fact it is not.
Showing
Please register or sign in to comment