~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/rename.cc

  • Committer: Jay Pipes
  • Date: 2009-03-25 16:24:51 UTC
  • mto: This revision was merged to the branch mainline in revision 965.
  • Revision ID: jpipes@serialcoder-20090325162451-n7s8734nwr6kaod1
Renamed some things to our standards and made private methods private...

Show diffs side-by-side

added added

removed removed

Lines of Context:
31
31
  Every second entry in the table_list is the original name and every
32
32
  second entry is the new name.
33
33
*/
34
 
 
35
34
bool drizzle_rename_tables(Session *session, TableList *table_list, bool silent)
36
35
{
37
36
  bool error= 1;
41
40
    Avoid problems with a rename on a table that we have locked or
42
41
    if the user is trying to to do this in a transcation context
43
42
  */
44
 
  if (session->locked_tables || session->active_transaction())
 
43
  if (session->locked_tables || session->inTransaction())
45
44
  {
46
 
    my_message(ER_LOCK_OR_ACTIVE_TRANSACTION,
47
 
               ER(ER_LOCK_OR_ACTIVE_TRANSACTION), MYF(0));
 
45
    my_message(ER_LOCK_OR_ACTIVE_TRANSACTION, ER(ER_LOCK_OR_ACTIVE_TRANSACTION), MYF(0));
48
46
    return(1);
49
47
  }
50
48