MySQL 8.0.39
Source Code Documentation
range_analysis.h
Go to the documentation of this file.
1/* Copyright (c) 2000, 2024, Oracle and/or its affiliates.
2
3 This program is free software; you can redistribute it and/or modify
4 it under the terms of the GNU General Public License, version 2.0,
5 as published by the Free Software Foundation.
6
7 This program is designed to work with certain software (including
8 but not limited to OpenSSL) that is licensed under separate terms,
9 as designated in a particular file or component or in included license
10 documentation. The authors of MySQL hereby grant you an additional
11 permission to link the program and your derivative works with the
12 separately licensed software that they have either included with
13 the program or referenced in the documentation.
14
15 This program is distributed in the hope that it will be useful,
16 but WITHOUT ANY WARRANTY; without even the implied warranty of
17 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 GNU General Public License, version 2.0, for more details.
19
20 You should have received a copy of the GNU General Public License
21 along with this program; if not, write to the Free Software
22 Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */
23
24#ifndef SQL_RANGE_OPTIMIZER_RANGE_ANALYSIS_H_
25#define SQL_RANGE_OPTIMIZER_RANGE_ANALYSIS_H_
26
27#include "my_table_map.h"
28
29class SEL_TREE;
30class RANGE_OPT_PARAM;
31class Item;
32class THD;
33
34/*
35 RangeAnalysisModule
36 A module that accepts a condition, index (or partitioning) description,
37 and builds lists of intervals (in index/partitioning space), such that
38 all possible records that match the condition are contained within the
39 intervals.
40 The entry point for the range analysis module is get_mm_tree()
41 (mm=min_max) function.
42
43 The lists are returned in form of complicated structure of interlinked
44 SEL_TREE/SEL_IMERGE/SEL_ROOT/SEL_ARG objects.
45 See quick_range_seq_next, find_used_partitions for examples of how to walk
46 this structure.
47 All direct "users" of this module are located within this file, too.
48
49 */
50SEL_TREE *get_mm_tree(THD *thd, RANGE_OPT_PARAM *param, table_map prev_tables,
51 table_map read_tables, table_map current_table,
52 bool remove_jump_scans, Item *cond);
53
54#endif // SQL_RANGE_OPTIMIZER_RANGE_ANALYSIS_H_
Base class that is used to represent any kind of expression in a relational query.
Definition: item.h:853
Definition: range_opt_param.h:29
Definition: tree.h:871
For each client connection we create a separate thread with THD serving as a thread/connection descri...
Definition: sql_lexer_thd.h:34
uint64_t table_map
Definition: my_table_map.h:30
SEL_TREE * get_mm_tree(THD *thd, RANGE_OPT_PARAM *param, table_map prev_tables, table_map read_tables, table_map current_table, bool remove_jump_scans, Item *cond)
The Range Analysis Module, which finds range access alternatives applicable to single or multi-index ...
Definition: range_analysis.cc:845