bug 857066 Wrong result with ST_DISJOINT when using an index.

DISJOINT can't be properly optimized with the RTree keys in MyISAM also.

per-file comments:
  storage/myisam/rt_index.c
bug 857066 Wrong result with ST_DISJOINT when using an index.
        don't optimize DISJOINT with the RTree keys.
This commit is contained in:
Alexey Botchkov 2011-11-29 15:27:52 +04:00
commit cdde6187d1

View file

@ -1028,7 +1028,7 @@ ha_rows rtree_estimate(MI_INFO *info, uint keynr, uchar *key,
ha_rows res = 0;
if (flag & MBR_DISJOINT)
return info->state->records;
return HA_POS_ERROR;
if ((root = info->s->state.key_root[keynr]) == HA_OFFSET_ERROR)
return HA_POS_ERROR;