Drizzled Public API Documentation

drizzled::LEX Class Reference
Inheritance diagram for drizzled::LEX:
drizzled::Query_tables_list

List of all members.

Public Member Functions

TableListunlink_first_table (bool *link_to_local)
void link_first_table_back (TableList *first, bool link_to_local)
void first_lists_tables_same ()
void cleanup_after_one_table_open ()
bool push_context (Name_resolution_context *context)
void pop_context ()
bool copy_db_to (char **p_db, size_t *p_db_length) const
Name_resolution_contextcurrent_context ()
bool is_single_level_stmt ()
 check if the statement is a single-level join
bool isCacheable ()
void setCacheable (bool val)
void reset ()
void setSumExprUsed ()
bool isSumExprUsed ()
void start (Session *session)
void end ()
message::Tabletable ()
message::Table::Fieldfield ()
void setField (message::Table::Field *arg)
void setExists ()
bool exists () const
void reset_query_tables_list (bool init)
void add_to_query_tables (TableList *table)
TableListfirst_not_own_table ()
void chop_off_not_own_tables ()

Public Attributes

Select_Lex_Unit unit
Select_Lex select_lex
Select_Lexcurrent_select
Select_Lexall_selects_list
char * length
char * dec
LEX_STRING name
Stringwild
file_exchangeexchange
select_resultresult
LEX_STRING ident
unsigned char * yacc_yyss
unsigned char * yacc_yyvs
Sessionsession
const CHARSET_INFOcharset
bool text_string_is_7bit
TableListleaf_tables_insert
List< Key_part_speccol_list
List< Key_part_specref_list
List< Stringinterval_list
List< Lex_Columncolumns
List< Item > * insert_list
List< Itemfield_list
List< Itemvalue_list
List< Itemupdate_list
List< List_itemmany_values
SetVarVector var_list
List< Name_resolution_contextcontext_stack
SQL_LIST auxiliary_table_list
SQL_LIST save_list
CreateFieldlast_field
Item_sumin_sum_func
plugin::Functionudf
uint32_t type
nesting_map allow_sum_func
enum_sql_command sql_command
statement::Statementstatement
bool expr_allows_subselect
thr_lock_type lock_option
enum enum_duplicates duplicates
union {
   enum ha_rkey_function   ha_rkey_mode
   enum xa_option_words   xa_opt
}; 
sql_var_t option_type
int nest_level
uint8_t describe
uint8_t derived_tables
bool ignore
bool use_only_table_context
bool escape_used
bool is_lex_started
bool is_cross
TableListquery_tables
TableList ** query_tables_last
TableList ** query_tables_own_last

Private Attributes

bool cacheable
bool sum_expr_used
message::Table_create_table
message::Table::Field_create_field
bool _exists

Detailed Description

Definition at line 803 of file sql_lex.h.


Member Function Documentation

bool drizzled::LEX::copy_db_to ( char **  p_db,
size_t *  p_db_length 
) const

This method should be called only during parsing. It is aware of compound statements (stored routine bodies) and will initialize the destination with the default database of the stored routine, rather than the default database of the connection it is parsed in. E.g. if one has no current database selected, or current database set to 'bar' and then issues:

CREATE PROCEDURE foo.p1() BEGIN SELECT * FROM t1 END//

t1 is meant to refer to foo.t1, not to bar.t1.

This method is needed to support this rule.

Returns:
true in case of error (parsing should be aborted, false in case of success

Definition at line 1917 of file sql_lex.cc.

bool drizzled::LEX::is_single_level_stmt ( ) [inline]

check if the statement is a single-level join

Returns:
result of the check
Return values:
trueThe statement doesn't contain subqueries, unions and stored procedure calls.
falseThere are subqueries, UNIONs or stored procedure calls.

Definition at line 964 of file sql_lex.h.

Referenced by drizzled::choose_plan(), and drizzled::execute_command().


Member Data Documentation

This is current used to store the name of a named key cache or a named savepoint. It should probably be refactored out into the eventual Command class built for the Keycache and Savepoint commands.

Definition at line 836 of file sql_lex.h.

This is used kind of like the "ident" member variable below, as a place to store certain names of identifiers. Unfortunately, it is used differently depending on the Command (SELECT on a derived table vs CREATE)

Definition at line 824 of file sql_lex.h.

Referenced by drizzled::statement::AlterTable::execute().


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