binlog coordinates corresponding to the dump".
The good news is that now mysqldump can be used to get an online backup of InnoDB *which works for
point-in-time recovery and replication slave creation*. Formerly, mysqldump --master-data --single-transaction
used to call in fact mysqldump --master-data, so the dump was not an online dump (took big lock all time of dump).
The only lock which is now taken in this patch is at the beginning of the dump: mysqldump does:
FLUSH TABLES WITH READ LOCK; START TRANSACTION WITH CONSISTENT SNAPSHOT; SHOW MASTER STATUS; UNLOCK TABLES;
so the lock time is in fact the time FLUSH TABLES WITH READ LOCK takes to return (can be 0 or very long, if
a table is undergoing a huge update).
I have done some more minor changes listed in the paragraph of mysqldump.c.
WL#2237 "WITH CONSISTENT SNAPSHOT clause for START TRANSACTION":
it's a START TRANSACTION which additionally starts a consistent read on all
capable storage engine (i.e. InnoDB). So, can serve as a replacement for
BEGIN; SELECT * FROM some_innodb_table LIMIT 1; which starts a consistent read too.
DROP DATABASE failed because of file ext not in TYPELIB of known extensions.
General solution - construct a TYPELIB at runtime instead of a static list.
the result takes its charset/collation
attributes from the character string,
e.g. SELECT func(NULL, _latin2'string')
now returns a latin2 result. This is
done by introducing a new derivation
(aka coercibility) level DERIVATION_IGNORABLE,
which is used with Item_null.
2. 'Pure' NULL is now BINARY(0), not CHAR(0).
I.e. NULL is now more typeless.
Bug #6479 ALTER TABLE ... changing charset fails for TEXT columns
Fix: use do_conv_blob rather than do_copy_blob
if the column's character sets are different.
1) fix so that missing blob tables don't prevent table from being
dropped
2) decrease size of blob part if record length exceeds max length
3) add test case for table wo/ corresponding blob table
4) init scan counters when sending scan_tabreq
Now thd->mem_root is a pointer to thd->main_mem_root and THR_MALLOC is a pointer to thd->mem_root.
This gives us the following benefits:
- Allow us to easily detect if arena has already been swapped before (this fixes a bug in setup_conds() where arena was swaped twice in some cases)
- Faster swaps of arenas (as we don't have to copy the whole MEM_ROOT)
- We don't anymore have to call my_pthread_setspecific_ptr(THR_MALLOC,...) to change where memory is alloced. Now it's enough to set thd->mem_root
Added cases for bugs #6307 and #6460.
sql_select.cc:
Fixed the problem of bug reports #6307 and #6460.
The reported wrong result sets were due to the fact that
the added call of the fix_fields method for the built
AND condition that joined WHERE and ON conditions
broke ON expression, as it removed extra AND levels
in the built condition.
It looks like that no attributes of the built condition
are needed, so we don't have to call fix_fields here.
My previous change that "set @a=NULL" doesn't change charset
fixed 'Bug #6321' as well. Prove with a new test that
FIELD(<uservariable content NULL>, ...) now works fine too.
Added a case for bug #6365.
item_cmpfunc.cc:
Fixed bug #6365 : Server crashed when list of values
in IN predicate contains NULL while the tested field is
of the character type and not of the default set;
e.g. when f in 'f IN (NULL,'aa') belongs to binary
character set, while the default character set is latin1.
"SHOW CREATE TABLE" mysql-4.0 and mysql-3.23
compatibiliry mode change:
Check that a binary collation adds 'binary'
suffix into a char() column definition in
mysql40 and mysql2323 modes. This allows
not to lose the column's case sensitivity
when loading the dump in pre-4.1 servers.
The idea of the fix is that the administrative statements
OPTIMIZE TABLE, REPAIR TABLE and ANALYZE TABLE should not
generate binlog errors if there is no errors on the master.
Added protocol::flush() for easier embedded-server code
Increase block allocation variables a bit as they where a bit too small for MySQL 4.1
Added option --silent to client_test
WL#2067 add features to mysqltest: "disable_error_abort" + "$mysql_errno"
$mysql_errno is a new builtin variable of mysqltest and contains the
return code of the last command send to the server.
"--disable_abort_on_error" switches the abort of mysqltest
after "unmasked" failing statements off.
"--enable_abort_on_error" switches the abort of mysqltest
after "unmasked" failing statements on. (default)
"Maskings" are
!$<error number> and --error <error number>
in the line before the statement to be checked.
The benefit of the option "--disable_abort_on_error" is that
- all statements after the failing statement are executed
- a r/<test>.reject will be produced
- it is possible to write test cases, which perform
code sequences depending on the return code of a single
statement
constant with a column. The string is converted into the column
character set. It conversion doesn't lose data, then operation
is possible. Otherwise, give an error, as it was earlier.