summaryrefslogtreecommitdiff
path: root/sql/sql_select.h
diff options
context:
space:
mode:
Diffstat (limited to 'sql/sql_select.h')
-rw-r--r--sql/sql_select.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/sql/sql_select.h b/sql/sql_select.h
index 7d794b71f4d..353c2b1d610 100644
--- a/sql/sql_select.h
+++ b/sql/sql_select.h
@@ -729,3 +729,9 @@ bool error_if_full_join(JOIN *join);
int report_error(TABLE *table, int error);
int safe_index_read(JOIN_TAB *tab);
COND *remove_eq_conds(THD *thd, COND *cond, Item::cond_result *cond_value);
+
+inline bool optimizer_flag(THD *thd, uint flag)
+{
+ return (thd->variables.optimizer_switch & flag);
+}
+