List:Internals« Previous MessageNext Message »
From:Jim Winstead Date:May 24 2005 9:21pm
Subject:bk commit into 4.1 tree (jimw:1.2291) BUG#10566
View as plain text  
Below is the list of changes that have just been committed into a local
4.1 repository of jimw. When jimw 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.2291 05/05/24 12:21:15 jimw@stripped +3 -0
  Increase limit of partial key length in MEMORY storage engine
  to the same as a full key. (Bug #10566)

  sql/ha_heap.h
    1.32 05/05/24 12:21:11 jimw@stripped +1 -0
    Add max_supported_key_part_length() method.

  mysql-test/t/heap.test
    1.21 05/05/24 12:21:11 jimw@stripped +9 -0
    Add test for bug #10566

  mysql-test/r/heap.result
    1.29 05/05/24 12:21:11 jimw@stripped +5 -0
    Update results

# 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:	jimw
# Host:	rama.(none)
# Root:	/home/jimw/my/mysql-4.1-10566

--- 1.31/sql/ha_heap.h	2005-05-04 06:05:53 -07:00
+++ 1.32/sql/ha_heap.h	2005-05-24 12:21:11 -07:00
@@ -53,6 +53,7 @@
   }
   const key_map *keys_to_use_for_scanning() { return &btree_keys; }
   uint max_supported_keys()          const { return MAX_KEY; }
+  uint max_supported_key_part_length() const { return MAX_KEY_LENGTH; }
   double scan_time() { return (double) (records+deleted) / 20.0+10; }
   double read_time(uint index, uint ranges, ha_rows rows)
   { return (double) rows /  20.0+1; }

--- 1.28/mysql-test/r/heap.result	2005-03-15 01:32:08 -08:00
+++ 1.29/mysql-test/r/heap.result	2005-05-24 12:21:11 -07:00
@@ -291,3 +291,8 @@
 1	7
 1	8
 drop table t1;
+create table t1 (c char(255), primary key(c(90)));
+insert into t1 values
("abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyz");
+insert into t1 values
("abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyz");
+ERROR 23000: Duplicate entry
'abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijkl'
for key 1
+drop table t1;

--- 1.20/mysql-test/t/heap.test	2005-03-15 01:32:08 -08:00
+++ 1.21/mysql-test/t/heap.test	2005-05-24 12:21:11 -07:00
@@ -224,3 +224,12 @@
 insert t1 (a) values (1);
 select * from t1;                                                               
 drop table t1;
+
+#
+# Bug #10566: Verify that we can create a prefixed key with length > 255
+#
+create table t1 (c char(255), primary key(c(90)));
+insert into t1 values
("abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyz");
+--error 1062
+insert into t1 values
("abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyz");
+drop table t1;
Thread
bk commit into 4.1 tree (jimw:1.2291) BUG#10566Jim Winstead24 May