MySQL 9.0.0
Source Code Documentation
|
#include <sql_executor.h>
Public Types | |
enum | Setup_func { NO_SETUP , MATERIALIZE_TABLE_FUNCTION , MATERIALIZE_DERIVED , MATERIALIZE_SEMIJOIN } |
enum | enum_op_type { OT_NONE , OT_AGGREGATE , OT_MATERIALIZE , OT_AGGREGATE_THEN_MATERIALIZE , OT_AGGREGATE_INTO_TMP_TABLE , OT_WINDOWING_FUNCTION , OT_BNL , OT_BKA } |
Public Member Functions | |
QEP_TAB () | |
void | init (JOIN_TAB *jt) |
Initializes the object from a JOIN_TAB. More... | |
void | cleanup () |
Item * | condition_optim () const |
void | set_condition_optim () |
bool | keyread_optim () const |
void | set_keyread_optim () |
bool | reversed_access () const |
void | set_reversed_access (bool arg) |
void | set_table (TABLE *t) |
uint | get_sj_strategy () const |
bool | do_firstmatch () const |
Return true if join_tab should perform a FirstMatch action. More... | |
bool | do_loosescan () const |
Return true if join_tab should perform a LooseScan action. More... | |
bool | starts_weedout () const |
Return true if join_tab starts a Duplicate Weedout action. More... | |
bool | finishes_weedout () const |
Return true if join_tab finishes a Duplicate Weedout action. More... | |
void | init_join_cache (JOIN_TAB *join_tab) |
A helper function that allocates appropriate join cache object and sets next_query_block function of previous tab. More... | |
uint | sjm_query_block_id () const |
bool | dynamic_range () const |
bool | use_order () const |
Use ordering provided by chosen index? More... | |
AccessPath * | access_path () |
Construct an access path for reading from this table in the query, using the access method that has been determined previously (e.g., table scan, ref access, optional sort afterwards, etc.). More... | |
void | push_index_cond (const JOIN_TAB *join_tab, uint keyno, Opt_trace_object *trace_obj) |
Try to extract and push the index condition down to table handler. More... | |
uint | effective_index () const |
Return the index used for a table in a QEP. More... | |
bool | pfs_batch_update (const JOIN *join) const |
QEP_TAB (const QEP_TAB &) | |
QEP_TAB & | operator= (const QEP_TAB &) |
Public Member Functions inherited from QEP_shared_owner | |
QEP_shared_owner () | |
void | share_qs (QEP_shared_owner *other) |
Instructs to share the QEP_shared with another owner. More... | |
void | set_qs (QEP_shared *q) |
JOIN * | join () const |
void | set_join (JOIN *j) |
plan_idx | idx () const |
void | set_idx (plan_idx i) |
qep_tab_map | idx_map () const |
TABLE * | table () const |
POSITION * | position () const |
void | set_position (POSITION *p) |
Semijoin_mat_exec * | sj_mat_exec () const |
void | set_sj_mat_exec (Semijoin_mat_exec *s) |
plan_idx | first_sj_inner () const |
plan_idx | last_sj_inner () const |
plan_idx | first_inner () const |
plan_idx | last_inner () const |
plan_idx | first_upper () const |
void | set_first_inner (plan_idx i) |
void | set_last_inner (plan_idx i) |
void | set_first_sj_inner (plan_idx i) |
void | set_last_sj_inner (plan_idx i) |
void | set_first_upper (plan_idx i) |
Index_lookup & | ref () const |
uint | index () const |
void | set_index (uint i) |
enum join_type | type () const |
void | set_type (enum join_type t) |
Item * | condition () const |
void | set_condition (Item *to) |
bool | condition_is_pushed_to_sort () const |
void | mark_condition_as_pushed_to_sort () |
Key_map & | keys () const |
ha_rows | records () const |
void | set_records (ha_rows r) |
AccessPath * | range_scan () const |
void | set_range_scan (AccessPath *q) |
table_map | prefix_tables () const |
table_map | added_tables () const |
Item_func_match * | ft_func () const |
void | set_ft_func (Item_func_match *f) |
void | set_prefix_tables (table_map prefix_tables, table_map prev_tables) |
void | add_prefix_tables (table_map tables) |
bool | is_single_inner_of_semi_join () const |
bool | is_inner_table_of_outer_join () const |
bool | is_first_inner_for_outer_join () const |
bool | is_single_inner_for_outer_join () const |
bool | has_guarded_conds () const |
bool | and_with_condition (Item *tmp_cond) |
Extend join_tab->cond by AND'ing add_cond to it. More... | |
void | set_skip_records_in_range (bool skip_records_in_range) |
bool | skip_records_in_range () const |
void | qs_cleanup () |
Public Attributes | |
Table_ref * | table_ref |
Pointer to table reference. More... | |
SJ_TMP_TABLE * | flush_weedout_table |
SJ_TMP_TABLE * | check_weed_out_table |
plan_idx | firstmatch_return |
uint | loosescan_key_len |
plan_idx | match_tab |
bool | rematerialize |
Dependent table functions have to be materialized on each new scan. More... | |
Setup_func | materialize_table = NO_SETUP |
bool | using_dynamic_range = false |
bool | needs_duplicate_removal = false |
true <=> remove duplicates on this table. More... | |
bool | not_used_in_distinct |
Item * | having |
HAVING condition for checking prior saving a record into tmp table. More... | |
enum QEP_TAB::enum_op_type | op_type = OT_NONE |
Temp_table_param * | tmp_table_param |
Filesort * | filesort |
ORDER * | filesort_pushed_order = nullptr |
If we pushed a global ORDER BY down onto this first table, that ORDER BY list will be preserved here. More... | |
uint | ref_item_slice |
Slice number of the ref items array to switch to before reading rows from this table. More... | |
Item * | m_condition_optim = nullptr |
Condition as it was set by the optimizer, used for EXPLAIN. More... | |
bool | m_keyread_optim |
True if only index is going to be read for this table. More... | |
bool | m_reversed_access |
True if reversed scan is used. More... | |
qep_tab_map | lateral_derived_tables_depend_on_me |
Maps of all lateral derived tables which should be refreshed when execution reads a new row from this table. More... | |
Mem_root_array< const AccessPath * > * | invalidators = nullptr |
Additional Inherited Members | |
Protected Attributes inherited from QEP_shared_owner | |
QEP_shared * | m_qs |
enum QEP_TAB::Setup_func |
|
inline |
QEP_TAB::QEP_TAB | ( | const QEP_TAB & | ) |
|
inline |
|
inline |
Return true if join_tab should perform a FirstMatch action.
|
inline |
Return true if join_tab should perform a LooseScan action.
|
inline |
|
inline |
Return true if join_tab finishes a Duplicate Weedout action.
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
Return true if join_tab starts a Duplicate Weedout action.
SJ_TMP_TABLE* QEP_TAB::check_weed_out_table |
Filesort* QEP_TAB::filesort |
If we pushed a global ORDER BY down onto this first table, that ORDER BY list will be preserved here.
plan_idx QEP_TAB::firstmatch_return |
SJ_TMP_TABLE* QEP_TAB::flush_weedout_table |
Item* QEP_TAB::having |
HAVING condition for checking prior saving a record into tmp table.
Mem_root_array<const AccessPath *>* QEP_TAB::invalidators = nullptr |
qep_tab_map QEP_TAB::lateral_derived_tables_depend_on_me |
Maps of all lateral derived tables which should be refreshed when execution reads a new row from this table.
uint QEP_TAB::loosescan_key_len |
Condition as it was set by the optimizer, used for EXPLAIN.
m_condition may be overwritten at a later stage.
bool QEP_TAB::m_keyread_optim |
True if only index is going to be read for this table.
This is the optimizer's decision.
bool QEP_TAB::m_reversed_access |
True if reversed scan is used.
This is the optimizer's decision.
plan_idx QEP_TAB::match_tab |
Setup_func QEP_TAB::materialize_table = NO_SETUP |
bool QEP_TAB::needs_duplicate_removal = false |
true <=> remove duplicates on this table.
bool QEP_TAB::not_used_in_distinct |
enum QEP_TAB::enum_op_type QEP_TAB::op_type = OT_NONE |
uint QEP_TAB::ref_item_slice |
Slice number of the ref items array to switch to before reading rows from this table.
bool QEP_TAB::rematerialize |
Dependent table functions have to be materialized on each new scan.
Table_ref* QEP_TAB::table_ref |
Pointer to table reference.
Temp_table_param* QEP_TAB::tmp_table_param |
bool QEP_TAB::using_dynamic_range = false |