Below is the list of changes that have just been committed into a local
5.1 repository of tomas. When tomas 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, 2007-04-16 13:08:09+02:00, tomas@stripped +3 -0
Bug #27710 Creating unique index fails during single user mode
- enable indexes to be used always, if in single user, reject will happen before, and if
it is kerlel doing stuff, it should always be allowed
mysql-test/r/ndb_single_user.result@stripped, 2007-04-16 13:08:07+02:00,
tomas@stripped +3 -2
Bug #27710 Creating unique index fails during single user mode
mysql-test/t/ndb_single_user.test@stripped, 2007-04-16 13:08:07+02:00,
tomas@stripped +5 -2
Bug #27710 Creating unique index fails during single user mode
storage/ndb/src/kernel/blocks/dbdict/Dbdict.cpp@stripped, 2007-04-16 13:08:07+02:00,
tomas@stripped +1 -0
Bug #27710 Creating unique index fails during single user mode
- enable indexes to be used always, if in single user, reject will happen before, and
if it is kerlel doing stuff, it should always be allowed
# 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: tomas
# Host: whalegate.ndb.mysql.com
# Root: /home/tomas/mysql-5.1-single-user
--- 1.123/storage/ndb/src/kernel/blocks/dbdict/Dbdict.cpp 2007-04-16 11:43:12 +02:00
+++ 1.124/storage/ndb/src/kernel/blocks/dbdict/Dbdict.cpp 2007-04-16 13:08:07 +02:00
@@ -8158,6 +8158,7 @@
w.add(DictTabInfo::NoOfKeyAttr, indexPtr.p->noOfPrimkey);
w.add(DictTabInfo::NoOfNullable, indexPtr.p->noOfNullAttr);
w.add(DictTabInfo::KeyLength, indexPtr.p->tupKeyLength);
+ w.add(DictTabInfo::SingleUserMode, (Uint32)1);
// write index key attributes
for (k = 0; k < opPtr.p->m_attrList.sz; k++) {
// insert the attributes in the order decided above in attrid_map
--- 1.7/mysql-test/r/ndb_single_user.result 2007-04-16 11:43:12 +02:00
+++ 1.8/mysql-test/r/ndb_single_user.result 2007-04-16 13:08:07 +02:00
@@ -55,11 +55,12 @@
update t1 set b=b+100 where a > 7;
delete from t1;
insert into t1 select * from t2;
+create unique index new_index on t1 (b,c);
drop table t1;
ERROR 42S02: Unknown table 't1'
-create index new_index on t1 (c);
+create index new_index_fail on t1 (c);
ERROR HY000: Got error 299 'Operation not allowed or aborted due to single user mode'
from NDBCLUSTER
-insert into t1 values
(1,1,0),(2,2,0),(3,3,0),(4,4,0),(5,5,0),(6,6,0),(7,7,0),(8,8,0),(9,9,0),(10,10,0);
+insert into t1 values
(21,21,0),(22,22,0),(23,23,0),(24,24,0),(25,25,0),(26,26,0),(27,27,0),(28,28,0),(29,29,0),(210,210,0);
ERROR HY000: Got error 299 'Operation not allowed or aborted due to single user mode'
from NDBCLUSTER
select * from t1 where a = 1;
ERROR HY000: Got error 299 'Operation not allowed or aborted due to single user mode'
from NDBCLUSTER
--- 1.4/mysql-test/t/ndb_single_user.test 2007-04-16 11:43:12 +02:00
+++ 1.5/mysql-test/t/ndb_single_user.test 2007-04-16 13:08:07 +02:00
@@ -76,15 +76,18 @@
# delete with full table scan
delete from t1;
insert into t1 select * from t2;
+# Bug #27710 Creating unique index fails during single user mode
+# - prior to bugfix this would fail
+create unique index new_index on t1 (b,c);
# test some sql on other mysqld
--connection server2
--error 1051
drop table t1;
--error 1296
-create index new_index on t1 (c);
+create index new_index_fail on t1 (c);
--error 1296
-insert into t1 values
(1,1,0),(2,2,0),(3,3,0),(4,4,0),(5,5,0),(6,6,0),(7,7,0),(8,8,0),(9,9,0),(10,10,0);
+insert into t1 values
(21,21,0),(22,22,0),(23,23,0),(24,24,0),(25,25,0),(26,26,0),(27,27,0),(28,28,0),(29,29,0),(210,210,0);
--error 1296
select * from t1 where a = 1;
--error 1296
| Thread |
|---|
| • bk commit into 5.1 tree (tomas:1.2591) BUG#27710 | tomas | 16 Apr |