summaryrefslogtreecommitdiff
path: root/storage/connect/mysql-test/connect/r/mysql_index.result
diff options
context:
space:
mode:
Diffstat (limited to 'storage/connect/mysql-test/connect/r/mysql_index.result')
-rw-r--r--storage/connect/mysql-test/connect/r/mysql_index.result13
1 files changed, 12 insertions, 1 deletions
diff --git a/storage/connect/mysql-test/connect/r/mysql_index.result b/storage/connect/mysql-test/connect/r/mysql_index.result
index 54acc7be08d..b6c34add632 100644
--- a/storage/connect/mysql-test/connect/r/mysql_index.result
+++ b/storage/connect/mysql-test/connect/r/mysql_index.result
@@ -7,7 +7,7 @@ msg char(100) DEFAULT NULL,
PRIMARY KEY (id)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
INSERT INTO t1 VALUES(1,'Un'),(3,'Trois'),(5,'Cinq');
-INSERT INTO t1 VALUES(2,'Two'),(4,'Four'),(6,'Six');
+INSERT INTO t1 VALUES(2,'Two'),(4,'Four'),(6,'Six'), (7,'seven');
SELECT * FROM t1;
id msg
1 Un
@@ -16,6 +16,7 @@ id msg
2 Two
4 Four
6 Six
+7 seven
#
# Make local MYSQL table with indexed id column
#
@@ -35,6 +36,7 @@ id msg
2 Two
4 Four
6 Six
+7 seven
SELECT * FROM t2 WHERE id = 3;
id msg
3 Trois
@@ -49,12 +51,14 @@ SELECT * FROM t2 WHERE id > 4;
id msg
5 Cinq
6 Six
+7 seven
SELECT * FROM t2 WHERE id >= 3;
id msg
3 Trois
4 Four
5 Cinq
6 Six
+7 seven
SELECT * FROM t2 WHERE id < 3;
id msg
1 Un
@@ -64,6 +68,10 @@ id msg
1 Un
5 Cinq
6 Six
+7 seven
+explain SELECT * FROM t2 WHERE id <= 3;
+id select_type table type possible_keys key key_len ref rows Extra
+1 SIMPLE t2 range PRIMARY PRIMARY 4 NULL 2 Using where
SELECT * FROM t2 WHERE id <= 3;
id msg
1 Un
@@ -87,6 +95,7 @@ id msg
4 Four
5 Cinq
6 Six
+7 seven
UPDATE t2 SET msg = 'Five' WHERE id = 5;
Warnings:
Note 1105 t1: 1 affected rows
@@ -98,6 +107,7 @@ id msg
2 Two
4 Four
6 Six
+7 seven
DELETE FROM t2 WHERE id = 4;
Warnings:
Note 1105 t1: 1 affected rows
@@ -108,6 +118,7 @@ id msg
5 Five
2 Two
6 Six
+7 seven
DROP TABLE t2;
DROP TABLE t1;
#