~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/sql_error.cc

Merged Eric from lp:~eday/drizzle/eday-merge

Show diffs side-by-side

added added

removed removed

Lines of Context:
47
47
#include <drizzled/item/empty_string.h>
48
48
#include <drizzled/item/return_int.h>
49
49
 
 
50
using namespace drizzled;
 
51
 
50
52
/*
51
53
  Store a new message in an error object
52
54
 
203
205
  field_list.push_back(new Item_return_int("Code",4, DRIZZLE_TYPE_LONG));
204
206
  field_list.push_back(new Item_empty_string("Message",DRIZZLE_ERRMSG_SIZE));
205
207
 
206
 
  if (session->protocol->sendFields(&field_list,
207
 
                                  Protocol::SEND_NUM_ROWS | Protocol::SEND_EOF))
208
 
    return(true);
 
208
  if (session->protocol->sendFields(&field_list))
 
209
    return true;
209
210
 
210
211
  DRIZZLE_ERROR *err;
211
212
  Select_Lex *sel= &session->lex->select_lex;
212
213
  Select_Lex_Unit *unit= &session->lex->unit;
213
214
  ha_rows idx= 0;
214
 
  Protocol *protocol=session->protocol;
 
215
  plugin::Protocol *protocol=session->protocol;
215
216
 
216
217
  unit->set_limit(sel);
217
218