Commit graph

156 commits

Author SHA1 Message Date
monty@mysql.com
db7efa2780 New handler::index_flags() definition to make it easy to check the full used key and a specific key part.
Added key part to optimize_range() to fix problems when using fields in key parts.
2004-07-08 15:45:25 +03:00
serg@serg.mylan
648a2fea15 Merge bk-internal.mysql.com:/home/bk/mysql-4.1/
into serg.mylan:/usr/home/serg/Abk/mysql-4.1
2004-06-30 11:26:49 +02:00
serg@serg.mylan
08738d2847 fowwlowup fixes for index_flags() 2004-06-30 10:40:15 +02:00
ram@gw.mysql.r18.ru
6acd105b16 Merge rkalimullin@bk-internal.mysql.com:/home/bk/mysql-4.1
into gw.mysql.r18.ru:/usr/home/ram/work/4.1.b4089
2004-06-29 13:51:35 +05:00
ram@gw.mysql.r18.ru
c0c1c3200a a fix (bug #4304: TRUNCATE <table of type BDB> , wrong result). 2004-06-29 13:49:50 +05:00
monty@mysql.com
f6765146c1 Added missing root user to mysql.user on windows. (Bug #4242)
Set default max_allowed_packet to be able to read help tables even if an my.cnf file with this option is present. (Bug #3938)
Don't use default arguments for ha_rnd_init()
Simple code cleanups since last pull
2004-06-25 18:49:36 +03:00
konstantin@mysql.com
f99224fe2d One more const method. 2004-06-25 01:30:43 +04:00
konstantin@mysql.com
b6cb8cb5f7 Followup to cleanup in handler interface. 2004-06-25 01:29:30 +04:00
guilhem@mysql.com
4a82bd4732 Final part of WL#1717 "innodb/binlog consistency". This is to resolve
a limitation of yesterday's implementation:
if there was an unfinished transaction (COMMIT not typed), and some MyISAM tables were
then updated, and then mysqld crashes, then at restart the server would use the too old
binlog offset known by InnoDB to cut the binlog, thus cutting the successful MyISAM
updates. We fix this by reporting the binlog offset into InnoDB even if InnoDB was not
affected at all by the update.
But the feature is still disabled until we decide if it can go into 4.1.3.
2004-06-24 11:38:57 +02:00
serg@serg.mylan
c03addab79 merged 2004-06-23 12:36:07 +02:00
serg@serg.mylan
3f1c4ba745 handler interface cleanups:
more logical table/index_flags
  return  HA_ERR_WRONG_COMMAND instead of abstract methods where appropriate
  max_keys and other limits renamed to max_supported_keys/etc
  max_keys/etc are now wrappers to max_supported_keys/etc 
  ha_index_init/ha_rnd_init/ha_index_end/ha_rnd_end are now wrappers to real {index,rnd}_{init,end} to enforce strict pairing
2004-06-23 12:29:05 +02:00
guilhem@mysql.com
e816a757db WL#1689 "Map OPTIMIZE TABLE to ALTER TABLE for InnoDB"
exactly it's mapped to "ALTER TABLE t; ANALYZE TABLE t;"
2004-06-10 16:41:24 +02:00
brian@brian-akers-computer.local
e24e1350a3 Merge baker@bk-internal.mysql.com:/home/bk/mysql-4.1
into brian-akers-computer.local:/Users/brian/mysql/mysql-4.1
2004-06-05 10:43:22 -07:00
monty@mysql.com
aabbacba8f New patch to ensure that InnoDB gets values for CFLAGS and CXXFLAGS 2004-05-28 10:41:38 +03:00
brian@avenger.(none)
72e7d69674 Added tests for archive. Cleaned up a merge mistake and added some information on how well archive compresses. 2004-05-25 13:27:01 -07:00
magnus@neptunus.(none)
15023e1b8f Fixed prototype of get_error_message to use String to return error message
WL#1747 and #1746 allow user to decide if ordered index should be created or not
2004-05-24 12:35:39 +02:00
brian@brian-akers-computer.local
9c84b9b691 Archive merge 2004-05-22 12:16:49 -07:00
brian@avenger.(none)
467cad0bfc First commit of archive example. Archive is a simple storage engine that handles inserts and selects. 2004-05-20 18:13:11 -07:00
magnus@neptunus.(none)
1f1b01e028 Merge 2004-05-17 09:57:02 +02:00
monty@mishka.local
314a8bf114 key_cmp -> key_cmp_if_same
New records_in_range() interface (similar to read_range())
Macros for faster bitmap handling
Simplify read_range() code (#WL1786)
New general key_cmp() function to compare keys
2004-05-16 14:48:32 +03:00
magnus@neptunus.(none)
97bf111f1d WL #1729 Handler: error text for NDB errors
- New solution after discussions with Sergei, no handler specific code or error messages should be in sql layer.
next_result, only check for error if check is -1
Improved index_read
2004-05-13 11:56:45 +02:00
ingo@mysql.com
5c4f83bbd9 Merge mysql.com:/home/mydev/mysql-4.1
into mysql.com:/home/mydev/mysql-4.1-wl1687
2004-05-07 11:13:58 +02:00
pem@mysql.comhem.se
d02d105916 Fixed (portability) bug in handler.h, and tried to silence cast warnings on some platforms. 2004-05-06 19:55:12 +02:00
ingo@mysql.com
784c9526ec WL#1687 - Optimize UNION DISTINCT ... UNION ALL (again).
HEAP: Copies the key count to a backup variable and sets the key count to zero.
That way, no HEAP function will ever try to touch any index.
Re-enabling is done by copying back the backup variable.
To avoid memory leak at table close, disable deletes all index trees.
Re-enabling must be done with empty indexes and data anyway. Otherwise,
the indexes would need to be repaired, wich HEAP is not capable of.
MyISAM: Only the key_map is cleared and set.
Re-enabling must be done with empty indexes and data. Otherwise, repair needs
to be done which will enable all keys persistently.
The former implementation disabled only non-unique keys and maked this persistent.
The new implementation additionally can disable all keys, but only without
making this persistent. Re-enabling all keys can be done without repair,
if data file and indexes are empty.
2004-05-06 15:53:01 +02:00
bell@sanja.is.com.ua
e9492cca05 avoid using ndb tables in query cache 2004-05-05 11:22:10 +03:00
magnus@neptunus.(none)
88478c28b1 Merge conflicts with EXAMPLE handler 2004-04-15 09:22:29 +02:00
magnus@neptunus.(none)
7c2c408cb8 Added NDB storage engine 2004-04-15 09:14:14 +02:00
brian@brian-akers-computer.local
86952cd9a6 Merge baker@bk-internal.mysql.com:/home/bk/mysql-4.1
into brian-akers-computer.local:/Users/brian/mysql/mysql-4.1-examples
2004-04-14 11:59:51 -04:00
brian@brian-akers-computer.local
4d5a8cb78c All changes are to allow someone to compile the example storage engine and use it. 2004-04-12 21:01:45 -07:00
monty@mysql.com
62fa4013ce Don't enable HA_EXTRA_WRITE_CACHE if too few rows
Revert main parts of patch for online index builds. Should be done differently
Added support for %lx in my_snprintf()
2004-04-08 17:56:45 +03:00
monty@mysql.com
00738a2be0 Merge bk-internal.mysql.com:/home/bk/mysql-4.1
into mysql.com:/home/my/mysql-4.1
2004-04-08 15:02:25 +03:00
monty@mysql.com
43546e7a82 Moved reading of ranges from opt_range.cc to handler.cc
This gives the handler more optimization possiblities and is needed for NDB cluster
Fixed not-initialized memory error detected by valgrind
2004-04-08 13:58:06 +03:00
serg@serg.mylan
1c0d4c4a46 merged 2004-04-07 17:14:38 +02:00
ingo@mysql.com
4de7e18b81 Hand-resolved auto merge 2004-04-07 14:56:24 +02:00
serg@serg.mylan
e8eda8129f ::reset(), HA_FAST_KEY_READ, disable_indexes(), enable_indexes(), start_bulk_insert(), end_bulk_insert()
Field::val_str simplification, comment
2004-04-06 21:35:26 +02:00
ingo@mysql.com
85ec87a094 Worklog#1563 - Support of on-line CREATE/DROP INDEX.
This is to enable table handlers to implement online create/drop index.
It consists of some parts:
- New default handler methods in handler.h
- Split of mysql_alter_table. It decides if only one kind of
  alteration is to be done (e.g. only create indexes or only drop
  indexes etc.) It then calls the specialized new handler method if
  the handler implements it. Otherwise it calls real_alter_table.
- The parser sets flags for each alter operation detected in a
  command. These are used by mysql_alter_table for the decision.
- mysql_prepare_table is pulled out of mysql_create_table. This is
  also used by mysql_create_index to prepare the key structure array
  for the handler. It is also used by mysql_create_index and
  mysql_drop_index to prepare a call to mysql_create_frm.
- mysql_create_frm is pulled out of rea_create_table for use by
  mysql_create_index and mysql_drop_index after the index is
  created/dropped.
Thanks to Antony who supplied most of the changes.
2004-03-30 19:22:14 +02:00
vva@eagle.mysql.r18.ru
8a66c13b34 fixed bug #2342
"Running ANALYZE TABLE on bdb table inside a transaction hangs server thread"
2004-03-27 02:29:31 +04:00
monty@mysql.com
ce14578909 Merge with 4.0.18 2004-02-11 00:06:46 +01:00
monty@mysql.com
079edf3313 Code cleanups 2004-02-10 12:03:08 +01:00
heikki@hundin.mysql.fi
d9790a406c row0mysql.c:
Allow always DROPping of a table which is only referenced by FOREIGN KEY constraints from the same table
Many files:
  Do not let REPLACE to perform internally an UPDATE if the table is referenced by a FOREIGN KEY: the manual says that REPLACE must resolve a duplicate key error semantically with DELETE(s) + INSERT, and not by an UPDATE; the internal update caused foreign key checks and cascaded operations to behave in a semantically wrong way
2004-02-09 23:57:29 +02:00
guilhem@mysql.com
e71325caf9 Fix for BUG#2477 "Slave stop with error after master reboot if use HEAP tables":
when we open the HEAP table for the first time since server restart,
in hp_open(), we set a flag to propagate this info to the handler level
which then writes a DELETE FROM this_heap_table to the binlog.
It is not a perfect solution for the bug, because between the server start and 
the first open of the table, the slave still had old data in his table so
a SELECT on the slave may show wrong content. But if there is a --init-file
to populate the HEAP table on master as startup, then this is a safe fix
(I'll put a note about init-file in the HEAP section of the manual).
2004-01-30 00:05:34 +01:00
monty@mysql.com
c1dd070ba7 Some small portability fixes.
Added support for lower_case_table_names=2, which is to be used on case insensitive file systems.
This tells MySQL to preserve the used case of filenames and database names to make it esier to move files between cases sensitive can case insensitive file systems (like Windows and Linux)
2003-12-30 13:14:21 +02:00
antony@ltantony.rdg.cyberkinetica.homeunix.net
2b53eef5f0 WorkLog #1323 (part 2)
New Statement: SHOW [STORAGE] ENGINES
New System Variable: storage_engine
New mysqld Argument: --default-storage-engine=
2003-12-17 22:52:03 +00:00
antony@ltantony.rdg.cyberkinetica.homeunix.net
afc619f0a2 WorkLog#1280 - Remove fixed table handler from lex/yacc 2003-12-02 20:23:13 +00:00
monty@mysql.com
7c6113a39f Merge key cache structures to one
Fixed compiler warnings (IRIX C compiler and VC++)
2003-11-20 22:06:25 +02:00
monty@mashka.mysql.fi
cab1dc628c CLIENT_MULTI_QUERIES -> CLIENT_MULTI_STATEMENTS
New multi-key-cache handling. This was needed becasue the old one didn't work reliable with MERGE tables.
ALTER TABLE table_name ... CHARACTER SET  ... now changes all char/varchar/text columns to the given character set
(One must use ALTER TABLE ... DEFAULT CHARACTER SET ... to change the default character set)
Fixed that have_compress is detected properly (fixes problems with func_compress.test on platforms without zlib)
New syntax for CACHE INDEX ('keys' is optional if no index name is given and one mentions the key cache name only ones)
Removed compiler warnings
Added mysql_set_server_option() to allow clients like PHP to easaily set/reset the multi-statement flag.
2003-11-18 13:47:27 +02:00
serg@serg.mylan
74551a72ec Merge bk-internal:/home/bk/mysql-4.1/
into serg.mylan:/usr/home/serg/Abk/mysql-4.1
2003-10-31 10:34:34 +01:00
igor@rurik.mysql.com
f29ed57531 Merge 2003-10-30 10:45:28 -08:00
serg@serg.mylan
6e17f4f20d fixes to Bitmap class 2003-10-24 22:44:48 +02:00
serg@serg.mylan
df69309593 MATCH ... AGAINST ("..." WITH QUERY EXPANSION) syntax 2003-10-22 17:57:09 +02:00