~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/sql_derived.cc

[patch 003/129] Merge patch for revision 1788 from InnoDB SVN:
revno: 1788
revision-id: svn-v4:16c675df-0fcb-4bc9-8058-dcc011a37293:branches/zip:5670
parent: svn-v4:16c675df-0fcb-4bc9-8058-dcc011a37293:branches/zip:5663
committer: marko
timestamp: Wed 2009-08-12 12:16:37 +0000
message:
  branches/zip: trx_undo_rec_copy(): Add const qualifier to undo_rec.
  This is a non-functional change.
modified:
  include/trx0rec.h              2@16c675df-0fcb-4bc9-8058-dcc011a37293:trunk%2Finclude%2Ftrx0rec.h
  include/trx0rec.ic             2@16c675df-0fcb-4bc9-8058-dcc011a37293:trunk%2Finclude%2Ftrx0rec.ic
  trx/trx0rec.c                  2@16c675df-0fcb-4bc9-8058-dcc011a37293:trunk%2Ftrx%2Ftrx0rec.c
diff:
=== modified file 'include/trx0rec.h'

Show diffs side-by-side

added added

removed removed

Lines of Context:
54
54
          Force join->join_tmp creation, because we will use this JOIN
55
55
          twice for EXPLAIN and we have to have unchanged join for EXPLAINing
56
56
        */
57
 
        sl->uncacheable.set(UNCACHEABLE_EXPLAIN);
58
 
        sl->master_unit()->uncacheable.set(UNCACHEABLE_EXPLAIN);
 
57
        sl->uncacheable|= UNCACHEABLE_EXPLAIN;
 
58
        sl->master_unit()->uncacheable|= UNCACHEABLE_EXPLAIN;
59
59
      }
60
60
    }
61
61
  }
144
144
    }
145
145
    else
146
146
    {
 
147
      if (! session->fill_derived_tables())
 
148
      {
 
149
        delete derived_result;
 
150
        derived_result= NULL;
 
151
      }
147
152
      orig_table_list->derived_result= derived_result;
148
153
      orig_table_list->table= table;
149
 
      orig_table_list->setTableName(const_cast<char *>(table->getShare()->getTableName()));
 
154
      orig_table_list->table_name=        const_cast<char *>(table->getShare()->getTableName());
150
155
      orig_table_list->table_name_length= table->getShare()->getTableNameSize();
151
156
      table->derived_select_number= first_select->select_number;
152
 
      orig_table_list->setSchemaName((char *)"");
 
157
      orig_table_list->db= (char *)"";
153
158
      orig_table_list->db_length= 0;
154
159
      /* Force read of table stats in the optimizer */
155
160
      table->cursor->info(HA_STATUS_VARIABLE);
156
161
      /* Add new temporary table to list of open derived tables */
157
 
      table->setNext(session->getDerivedTables());
158
 
      session->setDerivedTables(table);
 
162
      table->setNext(session->derived_tables);
 
163
      session->derived_tables= table;
159
164
    }
160
165
  }
161
166
 
214
219
                        first_select->item_list, first_select->where,
215
220
                        (first_select->order_list.elements+
216
221
                        first_select->group_list.elements),
217
 
                        (Order *) first_select->order_list.first,
218
 
                        (Order *) first_select->group_list.first,
 
222
                        (order_st *) first_select->order_list.first,
 
223
                        (order_st *) first_select->group_list.first,
219
224
                        first_select->having,
220
225
                        (first_select->options | session->options | SELECT_NO_UNLOCK),
221
226
                        derived_result, unit, first_select);