~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/optimizer/explain_plan.cc

Refactor

Show diffs side-by-side

added added

removed removed

Lines of Context:
31
31
#include <drizzled/join.h>
32
32
#include <drizzled/internal/m_string.h>
33
33
#include <drizzled/select_result.h>
 
34
#include <drizzled/sql_lex.h>
34
35
 
35
36
#include <cstdio>
36
37
#include <string>
99
100
    for (uint32_t i= 0; i < 7; i++)
100
101
      item_list.push_back(item_null);
101
102
 
102
 
    if (join->session->getLex()->describe & DESCRIBE_EXTENDED)
 
103
    if (join->session->lex().describe & DESCRIBE_EXTENDED)
103
104
      item_list.push_back(item_null);
104
105
 
105
106
    item_list.push_back(new Item_string(message,strlen(message),cs));
159
160
    /* ref */
160
161
    item_list.push_back(item_null);
161
162
    /* in_rows */
162
 
    if (join->session->getLex()->describe & DESCRIBE_EXTENDED)
 
163
    if (join->session->lex().describe & DESCRIBE_EXTENDED)
163
164
      item_list.push_back(item_null);
164
165
    /* rows */
165
166
    item_list.push_back(item_null);
314
315
                                       MY_INT64_NUM_DECIMAL_DIGITS));
315
316
 
316
317
      /* Add "filtered" field to item_list. */
317
 
      if (join->session->getLex()->describe & DESCRIBE_EXTENDED)
 
318
      if (join->session->lex().describe & DESCRIBE_EXTENDED)
318
319
      {
319
320
        float f= 0.0;
320
321
        if (examined_rows)
467
468
  {
468
469
    // drop UNCACHEABLE_EXPLAIN, because it is for internal usage only
469
470
    sl->uncacheable.reset(UNCACHEABLE_EXPLAIN);
470
 
    if (&session->getLex()->select_lex == sl)
 
471
    if (&session->lex().select_lex == sl)
471
472
    {
472
473
      if (sl->first_inner_unit() || sl->next_select())
473
474
      {
540
541
  }
541
542
  else
542
543
  {
543
 
    session->getLex()->current_select= first;
 
544
    session->lex().current_select= first;
544
545
    unit->set_limit(unit->global_parameters);
545
546
    res= select_query(session, 
546
547
                      &first->ref_pointer_array,