Navigation Menu

Skip to content

Commit

Permalink
mariadb55: force enabling cond_push
Browse files Browse the repository at this point in the history
Optimization for the following SQL requries cond_push:

  SELECT * FROM ...
	   WHERE MATCH(...) AGAINST(..) AND
		 int_column = int_value
	   ORDER BY ... LIMIT ...;

Should we use
  SET GLOBAL optimizer_switch='engine_condition_pushdown=on';
instead to enable cond_push?

MariaDB 5.5 disables cond_push by default. We can enable it by the
above "SET" command or this change.

MySQL doesn't disable cond_push...

fixes #1315

Reported by Kazuhiko Shiozaki. Thanks!!!
  • Loading branch information
kou committed Mar 20, 2012
1 parent a8d6b0e commit 4dd2982
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions ha_mroonga.cc
Expand Up @@ -1974,6 +1974,9 @@ ulonglong ha_mroonga::storage_table_flags() const
HA_CAN_GEOMETRY |
HA_CAN_RTREEKEYS;
//HA_HAS_RECORDS;
#ifdef HA_MUST_USE_TABLE_CONDITION_PUSHDOWN
flags |= HA_MUST_USE_TABLE_CONDITION_PUSHDOWN;
#endif
DBUG_RETURN(flags);
}

Expand Down

0 comments on commit 4dd2982

Please sign in to comment.