Commit 5362ca27 authored by unknown's avatar unknown
Browse files

Merge baker@bk-internal.mysql.com:/home/bk/mysql-5.0

into  zim.(none):/home/brian/mysql/fix-5.0


sql/ha_berkeley.cc:
  Auto merged
sql/ha_berkeley.h:
  Auto merged
sql/ha_innodb.cc:
  Auto merged
sql/ha_innodb.h:
  Auto merged
sql/ha_ndbcluster.cc:
  Auto merged
sql/ha_ndbcluster.h:
  Auto merged
sql/handler.h:
  Auto merged
sql/mysql_priv.h:
  Auto merged
parents a454c695 ed35cecd
Loading
Loading
Loading
Loading
+6 −6
Original line number Diff line number Diff line
@@ -323,17 +323,17 @@ execute stmt4;
Engine	Support	Comment
MyISAM	YES/NO	Default engine as of MySQL 3.23 with great performance
MEMORY	YES/NO	Hash based, stored in memory, useful for temporary tables
MRG_MYISAM	YES/NO	Collection of identical MyISAM tables
ISAM	YES/NO	Obsolete storage engine, now replaced by MyISAM
MRG_ISAM	YES/NO	Obsolete storage engine, now replaced by MERGE
InnoDB	YES/NO	Supports transactions, row-level locking, and foreign keys
BERKELEYDB	YES/NO	Supports transactions and page-level locking
NDBCLUSTER	YES/NO	Clustered, fault-tolerant, memory-based tables
BerkeleyDB	YES/NO	Supports transactions and page-level locking
BLACKHOLE	YES/NO	/dev/null storage engine (anything you write to it disappears)
EXAMPLE	YES/NO	Example storage engine
ARCHIVE	YES/NO	Archive storage engine
CSV	YES/NO	CSV storage engine
ndbcluster	YES/NO	Clustered, fault-tolerant, memory-based tables
FEDERATED	YES/NO	Federated MySQL storage engine
BLACKHOLE	YES/NO	/dev/null storage engine (anything you write to it disappears)
MRG_MYISAM	YES/NO	Collection of identical MyISAM tables
binlog	YES/NO	This is a meta storage engine to represent the binlog in a transaction
ISAM	YES/NO	Obsolete storage engine
drop table if exists t5;
prepare stmt1 from ' drop table if exists t5 ' ;
execute stmt1 ;
+5 −1
Original line number Diff line number Diff line
@@ -74,7 +74,11 @@


handlerton example_hton= {
  "CSV",
  "EXAMPLE",
  SHOW_OPTION_YES,
  "Example storage engine", 
  DB_TYPE_EXAMPLE_DB,
  NULL,    /* We do need to write one! */
  0,       /* slot */
  0,       /* savepoint size. */
  NULL,    /* close_connection */
+4 −15
Original line number Diff line number Diff line
@@ -56,6 +56,10 @@ static int tina_init= 0;

handlerton tina_hton= {
  "CSV",
  SHOW_OPTION_YES,
  "CSV storage engine", 
  DB_TYPE_CSV_DB,
  NULL,    /* One needs to be written! */
  0,       /* slot */
  0,       /* savepoint size. */
  NULL,    /* close_connection */
@@ -857,21 +861,6 @@ THR_LOCK_DATA **ha_tina::store_lock(THD *thd,
  return to;
}

/* 
  Range optimizer calls this.
  I need to update the information on this.
*/
ha_rows ha_tina::records_in_range(int inx,
                                  const byte *start_key,uint start_key_len,
                                  enum ha_rkey_function start_search_flag,
                                  const byte *end_key,uint end_key_len,
                                  enum ha_rkey_function end_search_flag)
{
  DBUG_ENTER("ha_tina::records_in_range ");
  DBUG_RETURN(records); // Good guess
}


/* 
  Create a table. You do not want to leave the table open after a call to
  this (the database will call ::open() if it needs to).
+0 −7
Original line number Diff line number Diff line
@@ -78,7 +78,6 @@ class ha_tina: public handler
   */
  virtual double scan_time() { return (double) (records+deleted) / 20.0+10; }
  /* The next method will never be called */
  virtual double read_time(ha_rows rows) { DBUG_ASSERT(0); return((double) rows /  20.0+1); }
  virtual bool fast_key_read() { return 1;}
  /* 
    TODO: return actual upper bound of number of records in the table.
@@ -110,12 +109,6 @@ class ha_tina: public handler
  int reset(void);
  int external_lock(THD *thd, int lock_type);
  int delete_all_rows(void);
  ha_rows records_in_range(int inx, const byte *start_key,uint start_key_len,
      enum ha_rkey_function start_search_flag,
      const byte *end_key,uint end_key_len,
      enum ha_rkey_function end_search_flag);
//  int delete_table(const char *from);
//  int rename_table(const char * from, const char * to);
  int create(const char *name, TABLE *form, HA_CREATE_INFO *create_info);

  THR_LOCK_DATA **store_lock(THD *thd, THR_LOCK_DATA **to,
+23 −9
Original line number Diff line number Diff line
@@ -116,7 +116,7 @@
*/

/* If the archive storage engine has been inited */
static bool archive_inited= 0;
static bool archive_inited= FALSE;
/* Variables for archive share methods */
pthread_mutex_t archive_mutex;
static HASH archive_open_tables;
@@ -137,7 +137,11 @@ static HASH archive_open_tables;

/* dummy handlerton - only to have something to return from archive_db_init */
handlerton archive_hton = {
  "archive",
  "ARCHIVE",
  SHOW_OPTION_YES,
  "Archive storage engine", 
  DB_TYPE_ARCHIVE_DB,
  archive_db_init,
  0,       /* slot */
  0,       /* savepoint size. */
  NULL,    /* close_connection */
@@ -176,18 +180,28 @@ static byte* archive_get_key(ARCHIVE_SHARE *share,uint *length,
    void

  RETURN
    &archive_hton OK
    0             Error
    FALSE       OK
    TRUE        Error
*/

handlerton *archive_db_init()
bool archive_db_init()
{
  archive_inited= 1;
  VOID(pthread_mutex_init(&archive_mutex, MY_MUTEX_INIT_FAST));
  DBUG_ENTER("archive_db_init");
  if (pthread_mutex_init(&archive_mutex, MY_MUTEX_INIT_FAST))
    goto error;
  if (hash_init(&archive_open_tables, system_charset_info, 32, 0, 0,
                (hash_get_key) archive_get_key, 0, 0))
    return 0;
  return &archive_hton;
  {
    VOID(pthread_mutex_destroy(&archive_mutex));
  }
  else
  {
    archive_inited= TRUE;
    DBUG_RETURN(FALSE);
  }
error:
  have_archive_db= SHOW_OPTION_DISABLED;	// If we couldn't use handler
  DBUG_RETURN(TRUE);
}

/*
Loading