~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/execute.cc

  • Committer: Mark Atwood
  • Date: 2011-10-07 05:07:22 UTC
  • mfrom: (2429.1.1 drizzle-build)
  • Revision ID: me@mark.atwood.name-20111007050722-eigkrbzyepmg900c
mergeĀ lp:~brianaker/drizzle/remove-copy-schema-test-pl

Show diffs side-by-side

added added

removed removed

Lines of Context:
35
35
{
36
36
}
37
37
 
38
 
void Execute::run(const char *arg, size_t length)
39
 
{
40
 
  run(std::string(arg, length));
41
 
}
42
 
 
43
 
void Execute::run(const std::string &execution_string, sql::ResultSet &result_set)
 
38
void Execute::run(str_ref execution_string, sql::ResultSet &result_set)
44
39
{
45
40
  if (not _session.isConcurrentExecuteAllowed())
46
41
  {
56
51
    // We set the current schema.  @todo do the same with catalog
57
52
    util::string::ptr schema(_session.schema());
58
53
    if (not schema->empty())
59
 
      new_session->set_db(*schema);
 
54
      new_session->set_schema(*schema);
60
55
    
61
56
    new_session->setConcurrentExecute(false);
62
57
    
84
79
    {
85
80
      boost::this_thread::restore_interruption dl(_session.getThreadInterupt());
86
81
      
87
 
      try {
 
82
      try 
 
83
      {
88
84
        thread->join();
89
85
      }
90
86
      catch(boost::thread_interrupted const&)
101
97
  }
102
98
}
103
99
 
104
 
void Execute::run(const std::string &execution_string)
 
100
void Execute::run(str_ref execution_string)
105
101
{
106
102
  if (not _session.isConcurrentExecuteAllowed())
107
103
  {
117
113
    // We set the current schema.  @todo do the same with catalog
118
114
    util::string::ptr schema(_session.schema());
119
115
    if (not schema->empty())
120
 
      new_session->set_db(*schema);
 
116
      new_session->set_schema(*schema);
121
117
 
122
118
    new_session->setConcurrentExecute(false);
123
119
 
143
139
    {
144
140
      boost::this_thread::restore_interruption dl(_session.getThreadInterupt());
145
141
 
146
 
      try {
 
142
      try 
 
143
      {
147
144
        thread->join();
148
145
      }
149
146
      catch(boost::thread_interrupted const&)