Below is the list of changes that have just been committed into a local
5.1 repository of evgen. When evgen does a push these changes will
be propagated to the main repository and, within 24 hours after the
push, to the public repository.
For information on how to access the public repository
see http://dev.mysql.com/doc/mysql/en/installing-source-tree.html
ChangeSet
1.2219 06/06/19 04:26:27 evgen@stripped +5 -0
rpl_log.test, rpl_stm_log.result:
Fixed failing test case
field.cc, item_cmpfunc.cc, select.result:
After merge fix
mysql-test/extra/rpl_tests/rpl_log.test
1.39 06/06/19 04:00:03 evgen@stripped +7 -4
Fixed failing test case
sql/field.cc
1.319 06/06/19 03:57:05 evgen@stripped +2 -2
After merge fix
sql/item_cmpfunc.cc
1.207 06/06/19 03:56:42 evgen@stripped +19 -4
After merge fix
mysql-test/r/rpl_stm_log.result
1.70 06/06/19 03:55:31 evgen@stripped +7 -7
Fixed failing test case
mysql-test/r/select.result
1.130 06/06/19 03:54:59 evgen@stripped +1 -65
After merge fix
# This is a BitKeeper patch. What follows are the unified diffs for the
# set of deltas contained in the patch. The rest of the patch, the part
# that BitKeeper cares about, is below these diffs.
# User: evgen
# Host: moonbone.local
# Root: /work/tmp_merge-5.1-opt-mysql
--- 1.318/sql/field.cc 2006-06-18 14:20:26 +04:00
+++ 1.319/sql/field.cc 2006-06-19 03:57:05 +04:00
@@ -50,8 +50,8 @@
#define BLOB_PACK_LENGTH_TO_MAX_LENGH(arg) \
((ulong) ((LL(1) << min(arg, 4) * 8) - LL(1)))
-#define ASSERT_COLUMN_MARKED_FOR_READ DBUG_ASSERT(!table->read_set || bitmap_is_set(table->read_set, field_index))
-#define ASSERT_COLUMN_MARKED_FOR_WRITE DBUG_ASSERT(!table->write_set || bitmap_is_set(table->write_set, field_index))
+#define ASSERT_COLUMN_MARKED_FOR_READ DBUG_ASSERT(!table || (!table->read_set || bitmap_is_set(table->read_set, field_index)))
+#define ASSERT_COLUMN_MARKED_FOR_WRITE DBUG_ASSERT(!table || (!table->write_set || bitmap_is_set(table->write_set, field_index)))
/*
Rules for merging different types of fields in UNION
--- 1.206/sql/item_cmpfunc.cc 2006-06-18 14:56:31 +04:00
+++ 1.207/sql/item_cmpfunc.cc 2006-06-19 03:56:42 +04:00
@@ -148,7 +148,7 @@
}
else if (res == Item::FUNC_ITEM)
{
- field= items[i]->tmp_table_field_from_field_type(0);
+ field= items[i]->tmp_table_field_from_field_type(0, 0);
if (field)
field->move_field(buff, &null_byte, 0);
break;
@@ -354,9 +354,21 @@
static bool convert_constant_item(THD *thd, Field *field, Item **item)
{
int result= 0;
+
if (!(*item)->with_subselect && (*item)->const_item())
{
+ TABLE *table= field->table;
+ ulong orig_sql_mode= thd->variables.sql_mode;
+ my_bitmap_map *old_write_map;
+ my_bitmap_map *old_read_map;
+
+ if (table)
+ {
+ old_write_map= dbug_tmp_use_all_columns(table, table->write_set);
+ old_read_map= dbug_tmp_use_all_columns(table, table->read_set);
+ }
/* For comparison purposes allow invalid dates like 2000-01-32 */
+ thd->variables.sql_mode|= MODE_INVALID_DATES;
if (!(*item)->save_in_field(field, 1) && !((*item)->null_value))
{
Item *tmp= new Item_int_with_ref(field->val_int(), *item,
@@ -365,9 +377,12 @@
thd->change_item_tree(item, tmp);
result= 1; // Item was replaced
}
- table->in_use->variables.sql_mode= orig_sql_mode;
- dbug_tmp_restore_column_map(table->write_set, old_write_map);
- dbug_tmp_restore_column_map(table->read_set, old_read_map);
+ thd->variables.sql_mode= orig_sql_mode;
+ if (table)
+ {
+ dbug_tmp_restore_column_map(table->write_set, old_write_map);
+ dbug_tmp_restore_column_map(table->read_set, old_read_map);
+ }
}
return result;
}
--- 1.129/mysql-test/r/select.result 2006-06-18 14:56:31 +04:00
+++ 1.130/mysql-test/r/select.result 2006-06-19 03:54:59 +04:00
@@ -2726,74 +2726,10 @@
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE t1 ALL NULL NULL NULL NULL 3
EXPLAIN SELECT * FROM t1 IGNORE INDEX (a);
-ERROR HY000: Key 'a' doesn't exist in table 't1'
-EXPLAIN SELECT * FROM t1 FORCE INDEX (a);
-ERROR HY000: Key 'a' doesn't exist in table 't1'
-DROP TABLE t1;
-CREATE TABLE t1 (a int, INDEX idx(a));
-INSERT INTO t1 VALUES (2), (3), (1);
-EXPLAIN SELECT * FROM t1 IGNORE INDEX (idx);
-id select_type table type possible_keys key key_len ref rows Extra
-1 SIMPLE t1 ALL NULL NULL NULL NULL 3
-EXPLAIN SELECT * FROM t1 IGNORE INDEX (a);
ERROR 42000: Key 'a' doesn't exist in table 't1'
+EXPLAIN SELECT * FROM t1 FORCE INDEX (a);
ERROR 42000: Key 'a' doesn't exist in table 't1'
DROP TABLE t1;
-CREATE TABLE t1 ( city char(30) );
-INSERT INTO t1 VALUES ('London');
-INSERT INTO t1 VALUES ('Paris');
-SELECT * FROM t1 WHERE city='London';
-city
-London
-SELECT * FROM t1 WHERE city='london';
-city
-London
-EXPLAIN SELECT * FROM t1 WHERE city='London' AND city='london';
-id select_type table type possible_keys key key_len ref rows Extra
-1 SIMPLE t1 ALL NULL NULL NULL NULL 2 Using where
-SELECT * FROM t1 WHERE city='London' AND city='london';
-city
-London
-EXPLAIN SELECT * FROM t1 WHERE city LIKE '%london%' AND city='London';
-id select_type table type possible_keys key key_len ref rows Extra
-1 SIMPLE t1 ALL NULL NULL NULL NULL 2 Using where
-SELECT * FROM t1 WHERE city LIKE '%london%' AND city='London';
-city
-London
-DROP TABLE t1;
-create table t1 (a int(11) unsigned, b int(11) unsigned);
-insert into t1 values (1,0), (1,1), (1,2);
-select a-b from t1 order by 1;
-a-b
-0
-1
-18446744073709551615
-select a-b , (a-b < 0) from t1 order by 1;
-a-b (a-b < 0)
-0 0
-1 0
-18446744073709551615 0
-select a-b as d, (a-b >= 0), b from t1 group by b having d >= 0;
-d (a-b >= 0) b
-1 1 0
-0 1 1
-18446744073709551615 1 2
-select cast((a - b) as unsigned) from t1 order by 1;
-cast((a - b) as unsigned)
-0
-1
-18446744073709551615
-drop table t1;
-create table t1 (a int(11));
-select all all * from t1;
-a
-select distinct distinct * from t1;
-a
-select all distinct * from t1;
-ERROR HY000: Incorrect usage of ALL and DISTINCT
-select distinct all * from t1;
-ERROR HY000: Incorrect usage of ALL and DISTINCT
-drop table t1;
CREATE TABLE t1 (
K2C4 varchar(4) character set latin1 collate latin1_bin NOT NULL default '',
K4N4 varchar(4) character set latin1 collate latin1_bin NOT NULL default '0000',
--- 1.69/mysql-test/r/rpl_stm_log.result 2006-06-18 14:56:31 +04:00
+++ 1.70/mysql-test/r/rpl_stm_log.result 2006-06-19 03:55:31 +04:00
@@ -95,6 +95,9 @@
# 127.0.0.1 root MASTER_PORT 1 master-bin.000002 388 # # master-bin.000002 Yes Yes # 0 0 388 # None 0 No #
show binlog events in 'slave-bin.000005' from 4;
ERROR HY000: Error when executing command SHOW BINLOG EVENTS: Could not find target log
+DROP TABLE t1;
+DROP TABLE t2;
+DROP TABLE t3;
create table t1(a int auto_increment primary key, b int);
insert into t1 values (NULL, 1);
reset master;
@@ -102,16 +105,13 @@
insert into t1 values (NULL, last_insert_id()), (NULL, last_insert_id());
show binlog events;
Log_name Pos Event_type Server_id End_log_pos Info
-slave-bin.000001 4 Format_desc 2 98 Server ver: VERSION, Binlog ver: 4
-slave-bin.000001 98 Intvar 2 126 LAST_INSERT_ID=1
-slave-bin.000001 126 Intvar 2 154 INSERT_ID=5
-slave-bin.000001 154 Query 2 289 use `test`; insert into t1 values (NULL, last_insert_id()), (NULL, last_insert_id())
+slave-bin.000001 # Format_desc 2 # Server ver: VERSION, Binlog ver: 4
+slave-bin.000001 # Intvar 2 # LAST_INSERT_ID=1
+slave-bin.000001 # Intvar 2 # INSERT_ID=5
+slave-bin.000001 # Query 2 # use `test`; insert into t1 values (NULL, last_insert_id()), (NULL, last_insert_id())
select * from t1;
a b
1 1
5 1
6 1
drop table t1;
-DROP TABLE t1;
-DROP TABLE t2;
-DROP TABLE t3;
--- 1.38/mysql-test/extra/rpl_tests/rpl_log.test 2006-06-18 14:56:31 +04:00
+++ 1.39/mysql-test/extra/rpl_tests/rpl_log.test 2006-06-19 04:00:03 +04:00
@@ -125,6 +125,12 @@
--error 1220
show binlog events in 'slave-bin.000005' from 4;
+# The table drops caused Cluster Replication wrapper to fail as event ID would never be the same.# Moving drops here.
+
+DROP TABLE t1;
+DROP TABLE t2;
+DROP TABLE t3;
+
#
# Bug #6880: LAST_INSERT_ID() within a statement
#
@@ -135,13 +141,10 @@
set insert_id=5;
insert into t1 values (NULL, last_insert_id()), (NULL, last_insert_id());
--replace_result $VERSION VERSION
+--replace_column 2 # 5 #
show binlog events;
select * from t1;
drop table t1;
# End of 4.1 tests
-# The table drops caused Cluster Replication wrapper to fail as event ID would never be the same.# Moving drops here.
-DROP TABLE t1;
-DROP TABLE t2;
-DROP TABLE t3;
| Thread |
|---|
| • bk commit into 5.1 tree (evgen:1.2219) | eugene | 19 Jun |