~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/statement/execute.cc

  • Committer: Brian Aker
  • Date: 2010-11-12 17:40:52 UTC
  • mto: (1932.2.1 trunk)
  • mto: This revision was merged to the branch mainline in revision 1930.
  • Revision ID: brian@tangent.org-20101112174052-4uy5fdet7xxsojb7
Fix so that an error causes a statement to fail/exit.

Show diffs side-by-side

added added

removed removed

Lines of Context:
124
124
        std::string full_string(to_execute.str, to_execute.length);
125
125
        Tokenizer tok(full_string, boost::escaped_list_separator<char>("\\", ";", "\""));
126
126
 
127
 
        std::cerr << "Execute String:" << full_string << "\n";
128
 
 
129
127
        for (Tokenizer::iterator iter= tok.begin();
130
 
             iter != tok.end() and not null_client->haveError() and getSession()->getKilled() != Session::KILL_CONNECTION;
 
128
             iter != tok.end() and getSession()->getKilled() != Session::KILL_CONNECTION;
131
129
             ++iter)
132
130
        {
133
131
          null_client->pushSQL(*iter);
134
132
          if (not getSession()->executeStatement())
135
 
          {
136
 
            break;
137
 
          }
 
133
            break;
 
134
 
 
135
          if (getSession()->is_error())
 
136
            break;
138
137
        }
139
138
      }
140
139