#include <ref_row_iterators.h>
◆ DynamicRangeIterator()
DynamicRangeIterator::DynamicRangeIterator |
( |
THD * |
thd, |
|
|
TABLE * |
table, |
|
|
QEP_TAB * |
qep_tab, |
|
|
ha_rows * |
examined_rows |
|
) |
| |
◆ ~DynamicRangeIterator()
DynamicRangeIterator::~DynamicRangeIterator |
( |
| ) |
|
|
override |
◆ Init()
bool DynamicRangeIterator::Init |
( |
| ) |
|
|
overridevirtual |
Initialize or reinitialize the iterator.
You must always call Init() before trying a Read() (but Init() does not imply Read()).
You can call Init() multiple times; subsequent calls will rewind the iterator (or reposition it, depending on whether the iterator takes in e.g. a Index_lookup) and allow you to read the records anew.
Implements RowIterator.
◆ Read()
int DynamicRangeIterator::Read |
( |
| ) |
|
|
overridevirtual |
Read a single row.
The row data is not actually returned from the function; it is put in the table's (or tables', in case of a join) record buffer, ie., table->records[0].
- Return values
-
0 | OK |
-1 | End of records |
1 | Error |
Implements RowIterator.
◆ m_examined_rows
ha_rows* const DynamicRangeIterator::m_examined_rows |
|
private |
◆ m_iterator
◆ m_mem_root
MEM_ROOT DynamicRangeIterator::m_mem_root |
|
private |
◆ m_qep_tab
QEP_TAB* DynamicRangeIterator::m_qep_tab |
|
private |
◆ m_quick_traced_before
bool DynamicRangeIterator::m_quick_traced_before = false |
|
private |
Used by optimizer tracing to decide whether or not dynamic range analysis of this select has been traced already.
If optimizer trace option DYNAMIC_RANGE is enabled, range analysis will be traced with different ranges for every record to the left of this table in the join. If disabled, range analysis will only be traced for the first range.
◆ m_read_set_with_base_columns
MY_BITMAP DynamicRangeIterator::m_read_set_with_base_columns |
|
private |
Read set to be used when range optimizer picks a non-covering index or when table scan gets picked.
It is setup by adding base columns to the read set setup by filter_gcol_for_dynamic_range_scan(). add_virtual_gcol_base_cols() adds the base columns when initializing this iterator.
◆ m_read_set_without_base_columns
MY_BITMAP* DynamicRangeIterator::m_read_set_without_base_columns |
|
private |
Read set to be used when range optimizer picks covering index.
This read set is same as what filter_gcol_for_dynamic_range_scan() sets up after filtering out the base columns for virtually generated columns from the original table read set. By filtering out the base columns, it avoids addition of unneeded columns for hash join/BKA.
The documentation for this class was generated from the following files: