Commit bedfbf87 authored by unknown's avatar unknown

BUG#23576, Table is created although tablespace does not exist


sql/ha_ndbcluster.cc:
  if use tablespace, that also means store on disk, so pass tablespace's name to ndb,
  then will get a error from ndb and its cause;
parent 479ffe15
...@@ -4706,10 +4706,18 @@ int ha_ndbcluster::create(const char *name, ...@@ -4706,10 +4706,18 @@ int ha_ndbcluster::create(const char *name,
} }
if (info->store_on_disk) if (info->store_on_disk)
{
if (info->tablespace) if (info->tablespace)
tab.setTablespace(info->tablespace); tab.setTablespace(info->tablespace);
else else
tab.setTablespace("DEFAULT-TS"); tab.setTablespace("DEFAULT-TS");
}
else if (info->tablespace)
{
tab.setTablespace(info->tablespace);
info->store_on_disk = true; //if use tablespace, that also means store on disk
}
// No primary key, create shadow key as 64 bit, auto increment // No primary key, create shadow key as 64 bit, auto increment
if (form->s->primary_key == MAX_KEY) if (form->s->primary_key == MAX_KEY)
{ {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment