mariadb/sql/ha_myisammrg.h
unknown 2901c3b8fa After merge fixes
Use server character set if --default-character-set is not used
Added convert_string() for more efficient alloc+character-set convert of strings


BitKeeper/deleted/.del-convert.result~a3b56e1db6f498e9:
  Delete: mysql-test/r/convert.result
BitKeeper/deleted/.del-convert.test~f4ceb743194dfe72:
  Delete: mysql-test/t/convert.test
BitKeeper/deleted/.del-make_win_src_distribution.old~5c9ebdc4a852b43b:
  Delete: scripts/make_win_src_distribution.old
client/mysql.cc:
  Use server character set if --default-character-set is not used
client/mysqltest.c:
  Code cleanup (merge identical code)
  More debug messages
heap/hp_create.c:
  After merge fix
include/m_ctype.h:
  After merge fix
include/my_global.h:
  Remove size_str (we already have size_s)
include/mysql_com.h:
  After merge fix
libmysql/libmysql.c:
  After merge fix
libmysqld/Makefile.am:
  After merge fix
mysql-test/r/auto_increment.result:
  After merge fix
mysql-test/r/create.result:
  After merge fix
mysql-test/r/ctype_latin1_de.result:
  After merge fix
mysql-test/r/distinct.result:
  After merge fix
mysql-test/r/drop.result:
  After merge fix
mysql-test/r/fulltext.result:
  After merge fix
mysql-test/r/func_gconcat.result:
  After merge fix
mysql-test/r/func_str.result:
  After merge fix
mysql-test/r/func_test.result:
  After merge fix
mysql-test/r/grant.result:
  After merge fix
mysql-test/r/group_by.result:
  After merge fix
mysql-test/r/handler.result:
  After merge fix
mysql-test/r/heap.result:
  After merge fix
mysql-test/r/heap_btree.result:
  After merge fix
mysql-test/r/heap_hash.result:
  After merge fix
mysql-test/r/innodb.result:
  After merge fix
mysql-test/r/insert.result:
  After merge fix
mysql-test/r/insert_select.result:
  After merge fix
mysql-test/r/join_outer.result:
  After merge fix
mysql-test/r/key.result:
  After merge fix
mysql-test/r/key_cache.result:
  After merge fix
mysql-test/r/loaddata.result:
  After merge fix
mysql-test/r/myisam.result:
  After merge fix
mysql-test/r/null.result:
  After merge fix
mysql-test/r/null_key.result:
  After merge fix
mysql-test/r/order_by.result:
  After merge fix
mysql-test/r/rpl_do_grant.result:
  After merge fix
mysql-test/r/rpl_error_ignored_table.result:
  After merge fix
mysql-test/r/rpl_ignore_grant.result:
  After merge fix
mysql-test/r/rpl_loaddata.result:
  After merge fix
mysql-test/r/rpl_log.result:
  After merge fix
mysql-test/r/rpl_log_pos.result:
  After merge fix
mysql-test/r/rpl_max_relay_size.result:
  After merge fix
mysql-test/r/rpl_replicate_do.result:
  After merge fix
mysql-test/r/rpl_reset_slave.result:
  After merge fix
mysql-test/r/rpl_rotate_logs.result:
  After merge fix
mysql-test/r/rpl_user_variables.result:
  After merge fix
mysql-test/r/select.result:
  After merge fix
mysql-test/r/select_safe.result:
  After merge fix
mysql-test/r/subselect.result:
  After merge fix
mysql-test/r/type_blob.result:
  After merge fix
mysql-test/r/type_decimal.result:
  After merge fix
mysql-test/r/type_float.result:
  After merge fix
mysql-test/r/type_ranges.result:
  After merge fix
mysql-test/r/type_time.result:
  After merge fix
mysql-test/r/type_uint.result:
  After merge fix
mysql-test/r/union.result:
  After merge fix
mysql-test/r/warnings.result:
  After merge fix
mysql-test/t/auto_increment.test:
  After merge fix
mysql-test/t/case.test:
  After merge fix
mysql-test/t/ctype_collate.test:
  After merge fix
mysql-test/t/ctype_latin1_de.test:
  After merge fix
mysql-test/t/drop.test:
  After merge fix
mysql-test/t/func_in.test:
  After merge fix
mysql-test/t/func_set.test:
  After merge fix
mysql-test/t/func_str.test:
  After merge fix
mysql-test/t/func_test.test:
  After merge fix
mysql-test/t/grant.test:
  After merge fix
mysql-test/t/group_by.test:
  After merge fix
mysql-test/t/handler.test:
  After merge fix
mysql-test/t/heap.test:
  After merge fix
mysql-test/t/heap_btree.test:
  After merge fix
mysql-test/t/heap_hash.test:
  After merge fix
mysql-test/t/innodb.test:
  After merge fix
mysql-test/t/insert_select.test:
  After merge fix
mysql-test/t/key.test:
  After merge fix
mysql-test/t/key_cache.test:
  After merge fix
mysql-test/t/lock_tables_lost_commit-master.opt:
  After merge fix
mysql-test/t/lock_tables_lost_commit.test:
  After merge fix
mysql-test/t/myisam.test:
  After merge fix
mysql-test/t/row.test:
  After merge fix
mysql-test/t/subselect.test:
  After merge fix
mysql-test/t/type_decimal.test:
  After merge fix
mysql-test/t/type_ranges.test:
  After merge fix
mysql-test/t/type_uint.test:
  After merge fix
mysql-test/t/variables.test:
  After merge fix
mysql-test/t/warnings.test:
  After merge fix
scripts/make_win_src_distribution.sh:
  after merge fixes
sql-common/client.c:
  After merge fix
  Change my_connect() to use poll()
  If character set is not given, use servers character set.
sql/field.cc:
  After merge fix
  Don't give warnings when storing data in fields in optimizer.
sql/ha_myisammrg.h:
  After merge fix
sql/log.cc:
  After merge fix
sql/log_event.cc:
  After merge fix
sql/mysqld.cc:
  After merge fix
sql/opt_range.cc:
  After merge fix
sql/set_var.cc:
  Code cleanup
  Fixed wrong usage of base_names (like medium.key_buffer) that caused core dumps
sql/set_var.h:
  Fixed wrong usage of base_names (like medium.key_buffer) that caused core dumps
sql/slave.cc:
  After merge fix
sql/sql_acl.cc:
  After merge fix
  Code cleanup
sql/sql_class.cc:
  Added convert_string() for more efficient alloc+character-set convert of strings
  Add cached flags to avoid calling mysql_charset_same() during parsing.
sql/sql_class.h:
  Added convert_string() for more efficient alloc+character-set convert of strings
  Add cached flags to avoid calling mysql_charset_same() during parsing.
sql/sql_handler.cc:
  After merge fix
sql/sql_lex.h:
  After merge fix
sql/sql_parse.cc:
  Optimize and fix memory reference errors reported by valgrind
sql/sql_repl.cc:
  After merge fix
sql/sql_yacc.yy:
  After merge fix
  Avoid calling mysql_charset_same() when parsing identifiers
strings/ctype-latin1.c:
  Port latin_de conversion code from 4.0
2003-08-19 00:08:08 +03:00

91 lines
3.5 KiB
C++

/* Copyright (C) 2000 MySQL AB & MySQL Finland AB & TCX DataKonsult AB
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#ifdef __GNUC__
#pragma interface /* gcc class implementation */
#endif
/* class for the the myisam merge handler */
#include <myisammrg.h>
class ha_myisammrg: public handler
{
MYRG_INFO *file;
public:
ha_myisammrg(TABLE *table): handler(table), file(0) {}
~ha_myisammrg() {}
const char *table_type() const { return "MRG_MyISAM"; }
const char **bas_ext() const;
ulong table_flags() const
{
return (HA_REC_NOT_IN_SEQ | HA_READ_RND_SAME | HA_AUTO_PART_KEY |
HA_KEYPOS_TO_RNDPOS | HA_LASTKEY_ORDER |
HA_NULL_KEY | HA_BLOB_KEY);
}
ulong index_flags(uint inx) const
{
ulong flags=(HA_READ_NEXT | HA_READ_PREV | HA_READ_ORDER);
return (flags | ((table->key_info[inx].algorithm == HA_KEY_ALG_FULLTEXT) ?
0 : HA_KEY_READ_ONLY));
}
uint max_record_length() const { return HA_MAX_REC_LENGTH; }
uint max_keys() const { return MI_MAX_KEY; }
uint max_key_parts() const { return MAX_REF_PARTS; }
uint max_key_length() const { return MAX_KEY_LENGTH; }
virtual double scan_time()
{ return ulonglong2double(data_file_length) / IO_SIZE + file->tables; }
int open(const char *name, int mode, uint test_if_locked);
int close(void);
int write_row(byte * buf);
int update_row(const byte * old_data, byte * new_data);
int delete_row(const byte * buf);
int index_read(byte * buf, const byte * key,
uint key_len, enum ha_rkey_function find_flag);
int index_read_idx(byte * buf, uint idx, const byte * key,
uint key_len, enum ha_rkey_function find_flag);
int index_read_last(byte * buf, const byte * key, uint key_len);
int index_next(byte * buf);
int index_prev(byte * buf);
int index_first(byte * buf);
int index_last(byte * buf);
int index_next_same(byte *buf, const byte *key, uint keylen);
int rnd_init(bool scan=1);
int rnd_next(byte *buf);
int rnd_pos(byte * buf, byte *pos);
void position(const byte *record);
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);
my_off_t row_position() { return myrg_position(file); }
void info(uint);
int extra(enum ha_extra_function operation);
int extra_opt(enum ha_extra_function operation, ulong cache_size);
int reset(void);
int external_lock(THD *thd, int lock_type);
uint lock_count(void) const;
int create(const char *name, TABLE *form, HA_CREATE_INFO *create_info);
THR_LOCK_DATA **store_lock(THD *thd, THR_LOCK_DATA **to,
enum thr_lock_type lock_type);
void update_create_info(HA_CREATE_INFO *create_info);
void append_create_info(String *packet);
MYRG_INFO *myrg_info() { return file; }
};