~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/message/statement_transform.cc

  • Committer: Brian Aker
  • Date: 2010-03-23 23:08:36 UTC
  • Revision ID: brian@gaz-20100323230836-p97twveqkt007r1j
Large reord in ALTER TABLE for RENAME.

Show diffs side-by-side

added added

removed removed

Lines of Context:
819
819
enum TransformSqlError
820
820
transformTableDefinitionToSql(const Table &table,
821
821
                              string &destination,
822
 
                              enum TransformSqlVariant sql_variant)
 
822
                              enum TransformSqlVariant sql_variant, bool with_schema)
823
823
{
824
824
  char quoted_identifier= '`';
825
825
  if (sql_variant == ANSI)
831
831
    destination.append("TEMPORARY ", 10);
832
832
  
833
833
  destination.append("TABLE ", 6);
 
834
  if (with_schema)
 
835
  {
 
836
    destination.push_back(quoted_identifier);
 
837
    destination.append(table.schema());
 
838
    destination.push_back(quoted_identifier);
 
839
    destination.push_back('.');
 
840
  }
834
841
  destination.push_back(quoted_identifier);
835
842
  destination.append(table.name());
836
843
  destination.push_back(quoted_identifier);