~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/sql_union.cc

  • Committer: Lee Bieber
  • Date: 2011-02-24 03:20:47 UTC
  • mfrom: (2196.1.4 build)
  • Revision ID: kalebral@gmail.com-20110224032047-avmw06iwww3m73cw
Merge Andrew - 723653: Docs day first pass fixes 
Merge Brian - Puts back in support for COM_KILL, Also adds back in the INTERACTIVE flag, and creates a DD to track sessions/check on usage
Merge Olaf - Use List::size()

Show diffs side-by-side

added added

removed removed

Lines of Context:
126
126
{
127
127
  assert(table == NULL);
128
128
  tmp_table_param.init();
129
 
  tmp_table_param.field_count= column_types->elements;
 
129
  tmp_table_param.field_count= column_types->size();
130
130
 
131
131
  if (! (table= create_tmp_table(session_arg, &tmp_table_param, *column_types,
132
132
                                 (Order*) NULL, is_union_distinct, 1,
279
279
                               sl->with_wild,
280
280
                               sl->where,
281
281
                               (can_skip_order_by ? 0 :
282
 
                                sl->order_list.elements) +
283
 
                               sl->group_list.elements,
 
282
                                sl->order_list.size()) +
 
283
                               sl->group_list.size(),
284
284
                               can_skip_order_by ?
285
285
                               (Order*) NULL : (Order *)sl->order_list.first,
286
286
                               (Order*) sl->group_list.first,
321
321
    }
322
322
    else
323
323
    {
324
 
      if (types.elements != sl->item_list.elements)
 
324
      if (types.size() != sl->item_list.size())
325
325
      {
326
326
        my_message(ER_WRONG_NUMBER_OF_COLUMNS_IN_SELECT,
327
327
                   ER(ER_WRONG_NUMBER_OF_COLUMNS_IN_SELECT),MYF(0));
371
371
    result_table_list.table= table= union_result->table;
372
372
 
373
373
    session_arg->getLex()->current_select= lex_select_save;
374
 
    if (!item_list.elements)
 
374
    if (!item_list.size())
375
375
    {
376
376
      saved_error= table->fill_item_list(&item_list);
377
377
      if (saved_error)
544
544
        saved_error= select_query(session, &fake_select_lex->ref_pointer_array,
545
545
                              &result_table_list,
546
546
                              0, item_list, NULL,
547
 
                              global_parameters->order_list.elements,
 
547
                              global_parameters->order_list.size(),
548
548
                              (Order*)global_parameters->order_list.first,
549
549
                              (Order*) NULL, NULL,
550
550
                              fake_select_lex->options | SELECT_NO_UNLOCK,
567
567
          saved_error= select_query(session, &fake_select_lex->ref_pointer_array,
568
568
                                &result_table_list,
569
569
                                0, item_list, NULL,
570
 
                                global_parameters->order_list.elements,
 
570
                                global_parameters->order_list.size(),
571
571
                                (Order*)global_parameters->order_list.first,
572
572
                                (Order*) NULL, NULL,
573
573
                                fake_select_lex->options | SELECT_NO_UNLOCK,
626
626
      join->tables= 0;
627
627
    }
628
628
    error|= fake_select_lex->cleanup();
629
 
    if (fake_select_lex->order_list.elements)
 
629
    if (fake_select_lex->order_list.size())
630
630
    {
631
631
      Order *ord;
632
632
      for (ord= (Order*)fake_select_lex->order_list.first; ord; ord= ord->next)