MySQL 8.4.0
Source Code Documentation
opt_explain_json_namespace::setop_ctx Class Reference

Node class for UNION, EXCEPT, INTERSECT, UNARY (query expression) More...

Inheritance diagram for opt_explain_json_namespace::setop_ctx:
[legend]

Public Member Functions

 setop_ctx (context *parent_arg, enum_parsing_context ctx, const char *str)
 
size_t id (bool hide) override
 Analogue of the "id" column in the traditional EXPLAIN output. More...
 
bool cacheable () override
 
bool dependent () override
 
void set_setop_result (setop_result_ctx *ctx) override
 associate CTX_UNION_RESULT node with CTX_UNION node More...
 
bool add_query_spec (context *ctx) override
 Add a query specification node to the CTX_UNION node. More...
 
- Public Member Functions inherited from opt_explain_json_namespace::unit_ctx
 unit_ctx (enum_parsing_context type_arg, const char *name_arg, context *parent_arg)
 
bool has_no_subqueries () const
 Helper function to distinguish subquery-less nodes. More...
 
bool format_query_expression (Opt_trace_context *json) override
 Helper function to format output for HAVING, ORDER/GROUP BY subqueries. More...
 
bool add_subquery (subquery_list_enum subquery_type, subquery_ctx *ctx) override
 Append a subquery node to the specified list of the unit node. More...
 
- Public Member Functions inherited from opt_explain_json_namespace::context
 context (enum_parsing_context type_arg, const char *name_arg, context *parent_arg)
 
virtual ~context ()=default
 
virtual bool format (Opt_trace_context *json)
 Pass the node with its child nodes to a JSON formatter. More...
 
bool is_query_block () const
 
virtual class qep_rowentry ()
 
virtual enum_mod_type get_mod_type ()
 
virtual void set_child (context *)
 Associate a child node with this node. More...
 
virtual bool format_nested_loop (Opt_trace_context *json)
 Format nested loop join subtree (if any) to JSON formatter. More...
 
virtual bool add_join_tab (joinable_ctx *ctx)
 Add a CTX_QEP_TAB node to a CTX_JOIN node. More...
 
virtual void set_sort (sort_ctx *ctx)
 Set nested ORDER BY/GROUP BY/DISTINCT node to ctx. More...
 
virtual void set_window (window_ctx *ctx)
 Set nested WINDOW node to ctx. More...
 
virtual bool find_and_set_derived (context *subquery)
 Try to associate a derived subquery node with this or underlying node. More...
 
virtual int add_where_subquery (subquery_ctx *ctx, Query_expression *subquery)
 Associate WHERE subqueries of given context and unit with this object. More...
 
virtual bool format_derived (Opt_trace_context *)
 Helper function to format output for derived subquery if any. More...
 
virtual bool format_where (Opt_trace_context *)
 Helper function to format output for associated WHERE subqueries if any. More...
 
- Public Member Functions inherited from Explain_context
 Explain_context (enum_parsing_context type_arg)
 

Private Member Functions

bool format_body (Opt_trace_context *json, Opt_trace_object *) override
 Format JSON object body. More...
 

Private Attributes

setop_result_ctxsetop_result
 associated e.g. CTX_UNION_RESULT node More...
 
List< contextquery_specs
 query specification nodes (inner selects) More...
 

Additional Inherited Members

- Public Attributes inherited from opt_explain_json_namespace::context
contextparent
 link to parent node or NULL More...
 
- Public Attributes inherited from Explain_context
enum_parsing_context type
 type tag More...
 
- Protected Attributes inherited from opt_explain_json_namespace::context
const char * name
 

Detailed Description

Node class for UNION, EXCEPT, INTERSECT, UNARY (query expression)

Constructor & Destructor Documentation

◆ setop_ctx()

opt_explain_json_namespace::setop_ctx::setop_ctx ( context parent_arg,
enum_parsing_context  ctx,
const char *  str 
)
inlineexplicit

Member Function Documentation

◆ add_query_spec()

bool opt_explain_json_namespace::setop_ctx::add_query_spec ( context ctx)
inlineoverridevirtual

Add a query specification node to the CTX_UNION node.

Parameters
ctxquery specification node
Return values
falseOk
trueError

Reimplemented from opt_explain_json_namespace::context.

◆ cacheable()

bool opt_explain_json_namespace::setop_ctx::cacheable ( )
inlineoverridevirtual

◆ dependent()

bool opt_explain_json_namespace::setop_ctx::dependent ( )
inlineoverridevirtual

◆ format_body()

bool opt_explain_json_namespace::setop_ctx::format_body ( Opt_trace_context json,
Opt_trace_object obj 
)
inlineoverrideprivatevirtual

Format JSON object body.

Parameters
jsonFormatter
objObject of this body
Return values
falseOk
trueError

Implements opt_explain_json_namespace::context.

◆ id()

size_t opt_explain_json_namespace::setop_ctx::id ( bool  hide)
inlineoverridevirtual

Analogue of the "id" column in the traditional EXPLAIN output.

Parameters
hideif true, ban the output of K_SELECT_ID JSON property in the underlying table_with_where_and_derived_ctx objects
Returns
"Select number" that is associated with this node

Implements opt_explain_json_namespace::context.

◆ set_setop_result()

void opt_explain_json_namespace::setop_ctx::set_setop_result ( setop_result_ctx )
inlineoverridevirtual

associate CTX_UNION_RESULT node with CTX_UNION node

Reimplemented from opt_explain_json_namespace::context.

Member Data Documentation

◆ query_specs

List<context> opt_explain_json_namespace::setop_ctx::query_specs
private

query specification nodes (inner selects)

◆ setop_result

setop_result_ctx* opt_explain_json_namespace::setop_ctx::setop_result
private

associated e.g. CTX_UNION_RESULT node


The documentation for this class was generated from the following file: