mirror of
https://github.com/MariaDB/server.git
synced 2025-07-29 05:21:33 +03:00
Auto-merge.
This commit is contained in:
@ -5709,6 +5709,27 @@ get_mm_leaf(RANGE_OPT_PARAM *param, COND *conf_func, Field *field,
|
||||
!(conf_func->compare_collation()->state & MY_CS_BINSORT))
|
||||
goto end;
|
||||
|
||||
if (key_part->image_type == Field::itMBR)
|
||||
{
|
||||
switch (type) {
|
||||
case Item_func::SP_EQUALS_FUNC:
|
||||
case Item_func::SP_DISJOINT_FUNC:
|
||||
case Item_func::SP_INTERSECTS_FUNC:
|
||||
case Item_func::SP_TOUCHES_FUNC:
|
||||
case Item_func::SP_CROSSES_FUNC:
|
||||
case Item_func::SP_WITHIN_FUNC:
|
||||
case Item_func::SP_CONTAINS_FUNC:
|
||||
case Item_func::SP_OVERLAPS_FUNC:
|
||||
break;
|
||||
default:
|
||||
/*
|
||||
We cannot involve spatial indexes for queries that
|
||||
don't use MBREQUALS(), MBRDISJOINT(), etc. functions.
|
||||
*/
|
||||
goto end;
|
||||
}
|
||||
}
|
||||
|
||||
if (param->using_real_indexes)
|
||||
optimize_range= field->optimize_range(param->real_keynr[key_part->key],
|
||||
key_part->part);
|
||||
|
Reference in New Issue
Block a user