MySQL  8.0.21
Source Code Documentation
Distinct_check Class Reference

Checks for queries which have DISTINCT. More...

#include <aggregate_check.h>

Inheritance diagram for Distinct_check:
Item_tree_walker

Public Member Functions

 Distinct_check (SELECT_LEX *select_arg)
 
bool check_query (THD *thd)
 Rejects the query if it has a combination of DISTINCT and ORDER BY which could lead to randomly ordered results. More...
 

Private Member Functions

 FORBID_COPY_CTOR_AND_ASSIGN_OP (Distinct_check)
 

Private Attributes

SELECT_LEX *const select
 Query block which we are validating. More...
 
Item_identfailed_ident
 Identifier which triggered an error. More...
 

Friends

bool Item_sum::aggregate_check_distinct (uchar *arg)
 Just because we need to go through Item::walk() to reach all items to validate, some work must be delegated to "Item processors" (members of Item); this work conceptually belongs to Distinct_check, and needs privileged access to it. More...
 
bool Item_ident::aggregate_check_distinct (uchar *arg)
 
bool Item_func_any_value::aggregate_check_distinct (uchar *arg)
 

Additional Inherited Members

- Protected Member Functions inherited from Item_tree_walker
 Item_tree_walker ()
 
 ~Item_tree_walker ()
 
void stop_at (const Item *i)
 Stops walking children of this item. More...
 
bool is_stopped (const Item *i)
 

Detailed Description

Checks for queries which have DISTINCT.

Constructor & Destructor Documentation

◆ Distinct_check()

Distinct_check::Distinct_check ( SELECT_LEX select_arg)
inline

Member Function Documentation

◆ FORBID_COPY_CTOR_AND_ASSIGN_OP()

Distinct_check::FORBID_COPY_CTOR_AND_ASSIGN_OP ( Distinct_check  )
private

Friends And Related Function Documentation

◆ Item_func_any_value::aggregate_check_distinct

◆ Item_ident::aggregate_check_distinct

◆ Item_sum::aggregate_check_distinct

Just because we need to go through Item::walk() to reach all items to validate, some work must be delegated to "Item processors" (members of Item); this work conceptually belongs to Distinct_check, and needs privileged access to it.

Member Data Documentation

◆ failed_ident

Item_ident* Distinct_check::failed_ident
private

Identifier which triggered an error.

◆ select

SELECT_LEX* const Distinct_check::select
private

Query block which we are validating.


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