Commit 40bf7b0a authored by unknown's avatar unknown
Browse files

This patch updates to remove most global hton needs. Cleans up wrong message in partition.


mysql-test/r/partition.result:
  Updated results
sql/ha_ndbcluster.cc:
  Updated hton
sql/ha_partition.cc:
  Removed need for global internal hton.
sql/handler.cc:
  Removed need for global mrg
sql/mysql_priv.h:
  Updated needs for global variables.
sql/mysqld.cc:
  Removed needs around hton
sql/partition_info.cc:
  Removed bug.... aka what happens if tables are neither?
sql/share/errmsg.txt:
  Made error message more generic.
sql/sql_cache.cc:
  Removed specific hton reference
parent 76b83865
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -68,7 +68,7 @@ create table t1 (a int)
engine = csv
partition by list (a)
(partition p0 values in (null));
ERROR HY000: CSV handler cannot be used in partitioned tables
ERROR HY000: Engine cannot be used in partitioned tables
create table t1 (a bigint)
partition by range (a)
(partition p0 values less than (0xFFFFFFFFFFFFFFFF),
@@ -102,7 +102,7 @@ create table t1 (a int)
engine = csv
partition by list (a)
(partition p0 values in (null));
ERROR HY000: CSV handler cannot be used in partitioned tables
ERROR HY000: Engine cannot be used in partitioned tables
create table t1 (a int)
partition by key(a)
(partition p0 engine = MEMORY);
@@ -1054,7 +1054,7 @@ drop table t1;
create table t1 (a int)
partition by key (a)
(partition p0 engine = MERGE);
ERROR HY000: MyISAM Merge handler cannot be used in partitioned tables
ERROR HY000: Engine cannot be used in partitioned tables
create table t1 (a varchar(1))
partition by key (a)
as select 'a';
+1 −1
Original line number Diff line number Diff line
@@ -87,7 +87,7 @@ static int ndbcluster_fill_files_table(handlerton *hton,
                                       TABLE_LIST *tables, 
                                       COND *cond);

handlerton *ndbcluster_hton;
static handlerton *ndbcluster_hton;

static handler *ndbcluster_create_handler(handlerton *hton,
                                          TABLE_SHARE *table,
+1 −1
Original line number Diff line number Diff line
@@ -75,11 +75,11 @@ static handler *partition_create_handler(handlerton *hton,
static uint partition_flags();
static uint alter_table_flags(uint flags);

handlerton *partition_hton;

static int partition_initialize(void *p)
{

  handlerton *partition_hton;
  partition_hton= (handlerton *)p;

  partition_hton->state= SHOW_OPTION_YES;
+3 −5
Original line number Diff line number Diff line
@@ -467,13 +467,11 @@ int ha_initialize_handlerton(st_plugin_int *plugin)
  }
  
  /* 
    This is entirely for legacy. We will create a new "disk based" hton and a "memory" hton
    which will be configurable longterm. 
    This is entirely for legacy. We will create a new "disk based" hton and a 
    "memory" hton which will be configurable longterm. We should be able to 
    remove partition and myisammrg.
  */
  switch (hton->db_type) {
  case DB_TYPE_MRG_ISAM:
    myisammrg_hton= hton;
    break;
  case DB_TYPE_HEAP:
    heap_hton= hton;
    break;
+0 −4
Original line number Diff line number Diff line
@@ -1638,11 +1638,7 @@ extern SHOW_COMP_OPTION have_ndbcluster;
extern SHOW_COMP_OPTION have_partition_db;
extern SHOW_COMP_OPTION have_merge_db;

#ifdef WITH_NDBCLUSTER_STORAGE_ENGINE
extern handlerton *ndbcluster_hton;
#endif
extern handlerton *partition_hton;
extern handlerton *myisammrg_hton;
extern handlerton *myisam_hton;
extern handlerton *heap_hton;

Loading