MySQL 8.4.3
Source Code Documentation
parse_tree_node_base.h File Reference
#include <assert.h>
#include <cstdarg>
#include <cstdlib>
#include <new>
#include <queue>
#include <typeinfo>
#include "memory_debugging.h"
#include "my_alloc.h"
#include "my_compiler.h"
#include "mem_root_deque.h"
#include "my_inttypes.h"
#include "sql-common/json_dom.h"
#include "sql/check_stack.h"
#include "sql/parse_location.h"
#include "sql/sql_const.h"
#include "sql/sql_list.h"

Go to the source code of this file.

Classes

struct  QueryLevel
 
class  Show_parse_tree
 Holds the json parse tree being generated by the SHOW PARSE_TREE command. More...
 
struct  Show_parse_tree::Parse_tree_comparator
 
class  Parse_tree_node_tmpl< Context >
 Base class for parse tree nodes (excluding the Parse_tree_root hierarchy) More...
 
struct  Parse_context_base
 
struct  Parse_context
 Environment data for the contextualization phase. More...
 

Macros

#define UNCACHEABLE_DEPENDENT   1
 
#define UNCACHEABLE_RAND   2
 
#define UNCACHEABLE_SIDEEFFECT   4
 
#define UNCACHEABLE_UNITED   8
 
#define UNCACHEABLE_CHECKOPTION   16
 

Typedefs

typedef Parse_tree_node_tmpl< Parse_contextParse_tree_node
 

Enumerations

enum  enum_parsing_context {
  CTX_NONE = 0 , CTX_MESSAGE , CTX_TABLE , CTX_SELECT_LIST ,
  CTX_UPDATE_VALUE , CTX_INSERT_VALUES , CTX_INSERT_UPDATE , CTX_JOIN ,
  CTX_QEP_TAB , CTX_MATERIALIZATION , CTX_DUPLICATES_WEEDOUT , CTX_DERIVED ,
  CTX_WHERE , CTX_ON , CTX_WINDOW , CTX_HAVING ,
  CTX_QUALIFY , CTX_ORDER_BY , CTX_GROUP_BY , CTX_SIMPLE_ORDER_BY ,
  CTX_SIMPLE_GROUP_BY , CTX_DISTINCT , CTX_SIMPLE_DISTINCT , CTX_BUFFER_RESULT ,
  CTX_ORDER_BY_SQ , CTX_GROUP_BY_SQ , CTX_OPTIMIZED_AWAY_SUBQUERY , CTX_UNION ,
  CTX_UNION_RESULT , CTX_INTERSECT , CTX_INTERSECT_RESULT , CTX_EXCEPT ,
  CTX_EXCEPT_RESULT , CTX_UNARY , CTX_UNARY_RESULT , CTX_QUERY_SPEC
}
 Names for different query parse tree parts. More...
 
enum  Surrounding_context {
  SC_TOP , SC_QUERY_SPECIFICATION , SC_TABLE_VALUE_CONSTRUCTOR , SC_QUERY_EXPRESSION ,
  SC_SUBQUERY , SC_UNION_DISTINCT , SC_UNION_ALL , SC_INTERSECT_DISTINCT ,
  SC_INTERSECT_ALL , SC_EXCEPT_DISTINCT , SC_EXCEPT_ALL
}
 

Macro Definition Documentation

◆ UNCACHEABLE_CHECKOPTION

#define UNCACHEABLE_CHECKOPTION   16

◆ UNCACHEABLE_DEPENDENT

#define UNCACHEABLE_DEPENDENT   1

◆ UNCACHEABLE_RAND

#define UNCACHEABLE_RAND   2

◆ UNCACHEABLE_SIDEEFFECT

#define UNCACHEABLE_SIDEEFFECT   4

◆ UNCACHEABLE_UNITED

#define UNCACHEABLE_UNITED   8

Typedef Documentation

◆ Parse_tree_node

Enumeration Type Documentation

◆ enum_parsing_context

Names for different query parse tree parts.

Enumerator
CTX_NONE 

Empty value.

CTX_MESSAGE 

"No tables used" messages etc.

CTX_TABLE 

for single-table UPDATE/DELETE/INSERT/REPLACE

CTX_SELECT_LIST 

SELECT (subquery), (subquery)...

CTX_UPDATE_VALUE 

UPDATE ... SET field=(subquery)...

CTX_INSERT_VALUES 

INSERT ... VALUES.

CTX_INSERT_UPDATE 

INSERT ... ON DUPLICATE KEY UPDATE ...

CTX_JOIN 
CTX_QEP_TAB 
CTX_MATERIALIZATION 
CTX_DUPLICATES_WEEDOUT 
CTX_DERIVED 

"Derived" subquery

CTX_WHERE 

Inside WHERE condition.

CTX_ON 

Inside ON condition.

CTX_WINDOW 

Named or unnamed window.

CTX_HAVING 

Inside HAVING condition.

CTX_QUALIFY 

Inside QUALIFY condition.

CTX_ORDER_BY 

ORDER BY clause execution context.

CTX_GROUP_BY 

GROUP BY clause execution context.

CTX_SIMPLE_ORDER_BY 

ORDER BY clause execution context.

CTX_SIMPLE_GROUP_BY 

GROUP BY clause execution context.

CTX_DISTINCT 

DISTINCT clause execution context.

CTX_SIMPLE_DISTINCT 

DISTINCT clause execution context.

CTX_BUFFER_RESULT 

see SQL_BUFFER_RESULT in the manual

CTX_ORDER_BY_SQ 

Subquery in ORDER BY clause item tree.

CTX_GROUP_BY_SQ 

Subquery in GROUP BY clause item tree.

CTX_OPTIMIZED_AWAY_SUBQUERY 

Subquery executed once during optimization.

CTX_UNION 
CTX_UNION_RESULT 

Pseudo-table context for UNION result.

CTX_INTERSECT 
CTX_INTERSECT_RESULT 

Pseudo-table context.

CTX_EXCEPT 
CTX_EXCEPT_RESULT 

Pseudo-table context.

CTX_UNARY 
CTX_UNARY_RESULT 

Pseudo-table context.

CTX_QUERY_SPEC 

Inner SELECTs of UNION expression.

◆ Surrounding_context

Enumerator
SC_TOP 
SC_QUERY_SPECIFICATION 
SC_TABLE_VALUE_CONSTRUCTOR 
SC_QUERY_EXPRESSION 
SC_SUBQUERY 
SC_UNION_DISTINCT 
SC_UNION_ALL 
SC_INTERSECT_DISTINCT 
SC_INTERSECT_ALL 
SC_EXCEPT_DISTINCT 
SC_EXCEPT_ALL