1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-08 11:22:35 +03:00

MDEV-14630 Replace {STRING|INT|REAL|DECIMAL|DATE}_ITEM to CONST_ITEM

This commit is contained in:
Alexander Barkov
2018-06-06 14:09:06 +04:00
parent 395212446a
commit c20cd68e60
11 changed files with 148 additions and 170 deletions

View File

@@ -2746,7 +2746,9 @@ const Item * ha_sphinx::cond_push ( const Item *cond )
if ( !m_pShare->m_bSphinxQL )
{
// on non-QL tables, intercept query=value condition for SELECT
if (!( args[0]->type()==Item::FIELD_ITEM && args[1]->type()==Item::STRING_ITEM ))
if (!( args[0]->type()==Item::FIELD_ITEM &&
args[1]->is_of_type(Item::CONST_ITEM,
STRING_RESULT)))
break;
Item_field * pField = (Item_field *) args[0];
@@ -2762,7 +2764,9 @@ const Item * ha_sphinx::cond_push ( const Item *cond )
} else
{
if (!( args[0]->type()==Item::FIELD_ITEM && args[1]->type()==Item::INT_ITEM ))
if (!( args[0]->type()==Item::FIELD_ITEM &&
args[1]->is_of_type(Item::CONST_ITEM,
INT_RESULT)))
break;
// on QL tables, intercept id=value condition for DELETE