~ubuntu-branches/ubuntu/trusty/drizzle/trusty

« back to all changes in this revision

Viewing changes to drizzled/statement/alter_schema.cc

  • Committer: Bazaar Package Importer
  • Author(s): Monty Taylor
  • Date: 2010-10-02 14:17:48 UTC
  • mfrom: (1.1.1 upstream)
  • mto: (2.1.17 sid)
  • mto: This revision was merged to the branch mainline in revision 3.
  • Revision ID: james.westby@ubuntu.com-20101002141748-m6vbfbfjhrw1153e
Tags: 2010.09.1802-1
* New upstream release.
* Removed pid-file argument hack.
* Updated GPL-2 address to be new address.
* Directly copy in drizzledump.1 since debian doesn't have sphinx 1.0 yet.
* Link to jquery from libjs-jquery. Add it as a depend.
* Add drizzled.8 symlink to the install files.

Show diffs side-by-side

added added

removed removed

Lines of Context:
37
37
  LEX_STRING *db= &session->lex->name;
38
38
  message::Schema old_definition;
39
39
 
40
 
  if (check_db_name(db))
 
40
  if (not validateSchemaOptions())
 
41
    return true;
 
42
 
 
43
  SchemaIdentifier schema_identifier(string(db->str, db->length));
 
44
 
 
45
  if (not check_db_name(session, schema_identifier))
41
46
  {
42
 
    my_error(ER_WRONG_DB_NAME, MYF(0), db->str);
 
47
    my_error(ER_WRONG_DB_NAME, MYF(0), schema_identifier.getSQLPath().c_str());
43
48
    return false;
44
49
  }
45
50
 
46
51
  schema_message.set_name(db->str);
 
52
  schema_message.mutable_engine()->set_name("filesystem"); // For the moment we have only one.
 
53
  SchemaIdentifier identifier(schema_message.name());
47
54
 
48
 
  if (not plugin::StorageEngine::getSchemaDefinition(schema_message.name(), old_definition))
 
55
  if (not plugin::StorageEngine::getSchemaDefinition(identifier, old_definition))
49
56
  {
50
57
    my_error(ER_SCHEMA_DOES_NOT_EXIST, MYF(0), db->str);
51
58
    return true;