diff options
author | Sergey Petrunya <psergey@askmonty.org> | 2011-06-22 01:57:28 +0400 |
---|---|---|
committer | Sergey Petrunya <psergey@askmonty.org> | 2011-06-22 01:57:28 +0400 |
commit | 6adddca80ec5ec972067917c54465d051b7d1cf4 (patch) | |
tree | a57908fb25ab407c1262a1873a1f436478191cb6 /sql/sql_select.h | |
parent | e1d734f383ce173871f8715eef273bdd0e070cc5 (diff) | |
download | mariadb-git-6adddca80ec5ec972067917c54465d051b7d1cf4.tar.gz |
Make semi-joins work with outer joins part #1:
- Make make_outerjoin_info() correctly process semi-join nests
- Make make_join_select() attach conditions to the right places.
Diffstat (limited to 'sql/sql_select.h')
-rw-r--r-- | sql/sql_select.h | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/sql/sql_select.h b/sql/sql_select.h index abb9a98030e..ae21db849ff 100644 --- a/sql/sql_select.h +++ b/sql/sql_select.h @@ -204,7 +204,13 @@ typedef struct st_join_table { NULL means no index condition pushdown was performed. */ Item *pre_idx_push_select_cond; - Item **on_expr_ref; /**< pointer to the associated on expression */ + /* + Pointer to the associated ON expression. on_expr_ref=!NULL except for + degenerate joins. + *on_expr_ref!=NULL for tables that are first inner tables within an outer + join. + */ + Item **on_expr_ref; COND_EQUAL *cond_equal; /**< multiple equalities for the on expression */ st_join_table *first_inner; /**< first inner table for including outerjoin */ bool found; /**< true after all matches or null complement */ @@ -478,6 +484,8 @@ typedef struct st_join_table { } double scan_time(); bool preread_init(); + + bool is_sjm_nest() { return test(bush_children); } } JOIN_TAB; |