List:Commits« Previous MessageNext Message »
From:igor Date:September 29 2006 6:36pm
Subject:bk commit into 5.0 tree (igor:1.2294)
View as plain text  
Below is the list of changes that have just been committed into a local
5.0 repository of igor. When igor 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@stripped, 2006-09-29 11:36:27-07:00, igor@stripped +2 -0
  Merge ibabaev@stripped:/home/bk/mysql-5.0-opt
  into  rurik.mysql.com:/home/igor/mysql-5.0-opt
  MERGE: 1.2292.1.1

  mysql-test/r/select.result@stripped, 2006-09-29 11:36:24-07:00, igor@stripped +6 -6
    Manual merge
    MERGE: 1.138.1.1

  mysql-test/t/select.test@stripped, 2006-09-29 11:36:24-07:00, igor@stripped +8 -10
    Manual merge
    MERGE: 1.112.1.1

# 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:	igor
# Host:	rurik.mysql.com
# Root:	/home/igor/mysql-5.0-opt/RESYNC

--- 1.139/mysql-test/r/select.result	2006-09-29 11:36:36 -07:00
+++ 1.140/mysql-test/r/select.result	2006-09-29 11:36:36 -07:00
@@ -3523,3 +3523,32 @@
 from t1 where c9=1 order by c2, c2;
 match (`c1`) against ('z')	c2	c3	c4	c5	c6	c7	c8
 drop table t1;
+CREATE TABLE t1 (pk varchar(10) PRIMARY KEY, fk varchar(16));
+CREATE TABLE t2 (pk varchar(16) PRIMARY KEY, fk varchar(10));
+INSERT INTO t1 VALUES
+('d','dddd'), ('i','iii'), ('a','aa'), ('b','bb'), ('g','gg'), 
+('e','eee'), ('c','cccc'), ('h','hhh'), ('j','jjj'), ('f','fff');
+INSERT INTO t2 VALUES
+('jjj', 'j'), ('cc','c'), ('ccc','c'), ('aaa', 'a'), ('jjjj','j'),
+('hhh','h'), ('gg','g'), ('fff','f'), ('ee','e'), ('ffff','f'),
+('bbb','b'), ('ff','f'), ('cccc','c'), ('dddd','d'), ('jj','j'),
+('aaaa','a'), ('bb','b'), ('eeee','e'), ('aa','a'), ('hh','h');
+EXPLAIN SELECT t2.* 
+FROM t1 JOIN t2 ON t2.fk=t1.pk
+WHERE t2.fk < 'c' AND t2.pk=t1.fk;
+id	select_type	table	type	possible_keys	key	key_len	ref	rows	Extra
+1	SIMPLE	t1	range	PRIMARY	PRIMARY	12	NULL	3	Using where
+1	SIMPLE	t2	ref	PRIMARY	PRIMARY	18	test.t1.fk	1	Using where
+EXPLAIN SELECT t2.* 
+FROM t1 JOIN t2 ON t2.fk=t1.pk 
+WHERE t2.fk BETWEEN 'a' AND 'b' AND t2.pk=t1.fk;
+id	select_type	table	type	possible_keys	key	key_len	ref	rows	Extra
+1	SIMPLE	t1	range	PRIMARY	PRIMARY	12	NULL	2	Using where
+1	SIMPLE	t2	ref	PRIMARY	PRIMARY	18	test.t1.fk	1	Using where
+EXPLAIN SELECT t2.* 
+FROM t1 JOIN t2 ON t2.fk=t1.pk 
+WHERE t2.fk IN ('a','b') AND t2.pk=t1.fk;
+id	select_type	table	type	possible_keys	key	key_len	ref	rows	Extra
+1	SIMPLE	t1	range	PRIMARY	PRIMARY	12	NULL	2	Using where
+1	SIMPLE	t2	ref	PRIMARY	PRIMARY	18	test.t1.fk	1	Using where
+DROP TABLE t1,t2;

--- 1.113/mysql-test/t/select.test	2006-09-29 11:36:36 -07:00
+++ 1.114/mysql-test/t/select.test	2006-09-29 11:36:36 -07:00
@@ -3007,3 +3007,29 @@
 select distinct match (`c1`) against ('z') , c2, c3, c4,c5, c6,c7, c8 
   from t1 where c9=1 order by c2, c2;
 drop table t1;
+# Bug #22735: no equality propagation for BETWEEN and IN with STRING arguments
+#
+
+CREATE TABLE t1 (pk varchar(10) PRIMARY KEY, fk varchar(16));
+CREATE TABLE t2 (pk varchar(16) PRIMARY KEY, fk varchar(10));
+
+INSERT INTO t1 VALUES
+  ('d','dddd'), ('i','iii'), ('a','aa'), ('b','bb'), ('g','gg'), 
+  ('e','eee'), ('c','cccc'), ('h','hhh'), ('j','jjj'), ('f','fff');
+INSERT INTO t2 VALUES
+  ('jjj', 'j'), ('cc','c'), ('ccc','c'), ('aaa', 'a'), ('jjjj','j'),
+  ('hhh','h'), ('gg','g'), ('fff','f'), ('ee','e'), ('ffff','f'),
+  ('bbb','b'), ('ff','f'), ('cccc','c'), ('dddd','d'), ('jj','j'),
+  ('aaaa','a'), ('bb','b'), ('eeee','e'), ('aa','a'), ('hh','h');
+
+EXPLAIN SELECT t2.* 
+  FROM t1 JOIN t2 ON t2.fk=t1.pk
+    WHERE t2.fk < 'c' AND t2.pk=t1.fk;
+EXPLAIN SELECT t2.* 
+  FROM t1 JOIN t2 ON t2.fk=t1.pk 
+    WHERE t2.fk BETWEEN 'a' AND 'b' AND t2.pk=t1.fk;
+EXPLAIN SELECT t2.* 
+  FROM t1 JOIN t2 ON t2.fk=t1.pk 
+    WHERE t2.fk IN ('a','b') AND t2.pk=t1.fk;
+
+DROP TABLE t1,t2;
Thread
bk commit into 5.0 tree (igor:1.2294)igor29 Sep