List:Commits« Previous MessageNext Message »
From:Martin Skold Date:December 7 2007 11:05am
Subject:bk commit into 5.1 tree (mskold:1.2588) BUG#21072
View as plain text  
Below is the list of changes that have just been committed into a local
5.1 repository of marty. When marty 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-12-07 11:05:19+01:00, mskold@stripped +7 -0
  bug#21072 Duplicate key error in NDB references wrong key: Post-merge fixes

  mysql-test/suite/ndb/r/ndb_charset.result@stripped, 2007-12-07 11:05:12+01:00,
mskold@stripped +4 -4
    bug#21072 Duplicate key error in NDB references wrong key: Post-merge fixes

  mysql-test/suite/ndb/r/ndb_index_unique.result@stripped, 2007-12-07 11:05:12+01:00,
mskold@stripped +7 -7
    bug#21072 Duplicate key error in NDB references wrong key: Post-merge fixes

  mysql-test/suite/ndb/r/ndb_update.result@stripped, 2007-12-07 11:05:13+01:00,
mskold@stripped +3 -3
    bug#21072 Duplicate key error in NDB references wrong key: Post-merge fixes

  sql/ha_ndbcluster.cc@stripped, 2007-12-07 11:05:12+01:00, mskold@stripped +0 -1
    bug#21072 Duplicate key error in NDB references wrong key: Post-merge fixes

  storage/ndb/include/ndbapi/NdbDictionary.hpp@stripped, 2007-12-07 11:05:12+01:00,
mskold@stripped +0 -5
    bug#21072 Duplicate key error in NDB references wrong key: Post-merge fixes

  storage/ndb/src/ndbapi/NdbDictionary.cpp@stripped, 2007-12-07 11:05:12+01:00,
mskold@stripped +0 -9
    bug#21072 Duplicate key error in NDB references wrong key: Post-merge fixes

  storage/ndb/src/ndbapi/NdbOperationExec.cpp@stripped, 2007-12-07 11:05:12+01:00,
mskold@stripped +1 -1
    bug#21072 Duplicate key error in NDB references wrong key: Post-merge fixes

diff -Nrup a/mysql-test/suite/ndb/r/ndb_charset.result
b/mysql-test/suite/ndb/r/ndb_charset.result
--- a/mysql-test/suite/ndb/r/ndb_charset.result	2007-12-07 10:35:32 +01:00
+++ b/mysql-test/suite/ndb/r/ndb_charset.result	2007-12-07 11:05:12 +01:00
@@ -112,9 +112,9 @@ unique key(a)
 ) engine=ndb;
 insert into t1 values(1, 'aAa');
 insert into t1 values(2, 'aaa');
-ERROR 23000: Duplicate entry '' for key '*UNKNOWN*'
+ERROR 23000: Duplicate entry 'aaa' for key 'a'
 insert into t1 values(3, 'AAA');
-ERROR 23000: Duplicate entry '' for key '*UNKNOWN*'
+ERROR 23000: Duplicate entry 'AAA' for key 'a'
 select * from t1 order by p;
 p	a
 1	aAa
@@ -138,9 +138,9 @@ unique key(a)
 ) engine=ndb;
 insert into t1 values (1,'A'),(2,'b '),(3,'C  '),(4,'d      '),(5,'E'),(6,'f');
 insert into t1 values(99,'b');
-ERROR 23000: Duplicate entry '' for key '*UNKNOWN*'
+ERROR 23000: Duplicate entry 'b' for key 'a'
 insert into t1 values(99,'a         ');
-ERROR 23000: Duplicate entry '' for key '*UNKNOWN*'
+ERROR 23000: Duplicate entry 'a         ' for key 'a'
 select a,length(a) from t1 order by a;
 a	length(a)
 A	1
diff -Nrup a/mysql-test/suite/ndb/r/ndb_index_unique.result
b/mysql-test/suite/ndb/r/ndb_index_unique.result
--- a/mysql-test/suite/ndb/r/ndb_index_unique.result	2007-12-07 10:35:39 +01:00
+++ b/mysql-test/suite/ndb/r/ndb_index_unique.result	2007-12-07 11:05:12 +01:00
@@ -22,7 +22,7 @@ select * from t1 where b = 4 order by a;
 a	b	c
 3	4	6
 insert into t1 values(8, 2, 3);
-ERROR 23000: Duplicate entry '' for key '*UNKNOWN*'
+ERROR 23000: Duplicate entry '2' for key 'ib'
 select * from t1 order by a;
 a	b	c
 1	2	3
@@ -93,7 +93,7 @@ a	b	c
 1	1	1
 4	4	NULL
 insert into t1 values(5,1,1);
-ERROR 23000: Duplicate entry '' for key '*UNKNOWN*'
+ERROR 23000: Duplicate entry '1-1' for key 'bc'
 drop table t1;
 CREATE TABLE t2 (
 a int unsigned NOT NULL PRIMARY KEY,
@@ -116,7 +116,7 @@ select * from t2 where b = 4 order by a;
 a	b	c
 3	4	6
 insert into t2 values(8, 2, 3);
-ERROR 23000: Duplicate entry '' for key '*UNKNOWN*'
+ERROR 23000: Duplicate entry '2-3' for key 'b'
 select * from t2 order by a;
 a	b	c
 1	2	3
@@ -139,7 +139,7 @@ a	b	c
 8	2	3
 create unique index bi using hash on t2(b);
 insert into t2 values(9, 3, 1);
-ERROR 23000: Duplicate entry '' for key '*UNKNOWN*'
+ERROR 23000: Duplicate entry '3' for key 'bi'
 alter table t2 drop index bi;
 insert into t2 values(9, 3, 1);
 select * from t2 order by a;
@@ -229,7 +229,7 @@ pk	a
 3	NULL
 4	4
 insert into t1 values (5,0);
-ERROR 23000: Duplicate entry '' for key '*UNKNOWN*'
+ERROR 23000: Duplicate entry '0' for key 'a'
 select * from t1 order by pk;
 pk	a
 -1	NULL
@@ -262,7 +262,7 @@ pk	a	b	c
 0	NULL	18	NULL
 1	3	19	abc
 insert into t2 values(2,3,19,'abc');
-ERROR 23000: Duplicate entry '' for key '*UNKNOWN*'
+ERROR 23000: Duplicate entry '3-abc' for key 'si'
 select * from t2 order by pk;
 pk	a	b	c
 -1	1	17	NULL
@@ -682,7 +682,7 @@ create table t1 (a int primary key, b va
 engine=ndb charset=utf8;
 insert into t1 values (1, repeat(_utf8 0xe288ab6474, 200));
 insert into t1 values (2, repeat(_utf8 0xe288ab6474, 200));
-ERROR 23000: Duplicate entry '' for key '*UNKNOWN*'
+ERROR 23000: Duplicate entry
'∫dt∫dt∫dt∫dt∫dt∫dt∫dt∫dt∫dt∫dt∫dt∫dt∫d'
for key 'b'
 select a, sha1(b) from t1;
 a	sha1(b)
 1	08f5d02c8b8bc244f275bdfc22c42c5cab0d9d7d
diff -Nrup a/mysql-test/suite/ndb/r/ndb_update.result
b/mysql-test/suite/ndb/r/ndb_update.result
--- a/mysql-test/suite/ndb/r/ndb_update.result	2007-12-07 10:35:45 +01:00
+++ b/mysql-test/suite/ndb/r/ndb_update.result	2007-12-07 11:05:13 +01:00
@@ -28,7 +28,7 @@ pk1	b	c
 2	2	2
 4	1	1
 UPDATE t1 set pk1 = 1, c = 2 where pk1 = 4;
-ERROR 23000: Duplicate entry '' for key '*UNKNOWN*'
+ERROR 23000: Duplicate entry '2' for key 'c'
 UPDATE IGNORE t1 set pk1 = 1, c = 2 where pk1 = 4;
 select * from t1 order by pk1;
 pk1	b	c
@@ -62,9 +62,9 @@ INSERT INTO t3 VALUES (2, 2);
 UPDATE t1 SET a = 1;
 UPDATE t1 SET a = 1 ORDER BY a;
 UPDATE t2 SET a = 1;
-ERROR 23000: Duplicate entry '' for key '*UNKNOWN*'
+ERROR 23000: Duplicate entry '1-2' for key 'a'
 UPDATE t2 SET a = 1 ORDER BY a;
-ERROR 23000: Duplicate entry '' for key '*UNKNOWN*'
+ERROR 23000: Duplicate entry '1-2' for key 'a'
 UPDATE t3 SET a = 1;
 ERROR 23000: Duplicate entry '1-2' for key 'PRIMARY'
 UPDATE t3 SET a = 1 ORDER BY a;
diff -Nrup a/sql/ha_ndbcluster.cc b/sql/ha_ndbcluster.cc
--- a/sql/ha_ndbcluster.cc	2007-12-07 10:46:11 +01:00
+++ b/sql/ha_ndbcluster.cc	2007-12-07 11:05:12 +01:00
@@ -599,7 +599,6 @@ int ha_ndbcluster::ndb_err(NdbTransactio
         const NDBINDEX *unique_index=
           (const NDBINDEX *) m_index[i].unique_index;
         if (unique_index &&
-            unique_index->getIndexTable() &&
             (uint) unique_index->getObjectId() == error_data)
         {
           dupkey= i;
diff -Nrup a/storage/ndb/include/ndbapi/NdbDictionary.hpp
b/storage/ndb/include/ndbapi/NdbDictionary.hpp
--- a/storage/ndb/include/ndbapi/NdbDictionary.hpp	2007-12-07 10:34:48 +01:00
+++ b/storage/ndb/include/ndbapi/NdbDictionary.hpp	2007-12-07 11:05:12 +01:00
@@ -1022,11 +1022,6 @@ public:
     const char * getTable() const;
 
     /**
-     * Get the table representing the index
-     */
-    const Table * getIndexTable() const;
-
-    /**
      * Get the number of columns in the index
      */
     unsigned getNoOfColumns() const;
diff -Nrup a/storage/ndb/src/ndbapi/NdbDictionary.cpp
b/storage/ndb/src/ndbapi/NdbDictionary.cpp
--- a/storage/ndb/src/ndbapi/NdbDictionary.cpp	2007-12-07 10:34:48 +01:00
+++ b/storage/ndb/src/ndbapi/NdbDictionary.cpp	2007-12-07 11:05:12 +01:00
@@ -792,15 +792,6 @@ NdbDictionary::Index::getTable() const {
   return m_impl.getTable();
 }
 
-const NdbDictionary::Table *
-NdbDictionary::Index::getIndexTable() const {
-  NdbTableImpl * t = m_impl.m_table;
-  if (t) {
-    return t->m_facade;
-  }
-  return 0;
-}
-
 unsigned
 NdbDictionary::Index::getNoOfColumns() const {
   return m_impl.m_columns.size();
diff -Nrup a/storage/ndb/src/ndbapi/NdbOperationExec.cpp
b/storage/ndb/src/ndbapi/NdbOperationExec.cpp
--- a/storage/ndb/src/ndbapi/NdbOperationExec.cpp	2007-12-07 10:46:11 +01:00
+++ b/storage/ndb/src/ndbapi/NdbOperationExec.cpp	2007-12-07 11:05:12 +01:00
@@ -549,7 +549,7 @@ NdbOperation::receiveTCKEYREF( NdbApiSig
   if (aSignal->getLength() == TcKeyRef::SignalLength)
   {
     // Signal may contain additional error data
-    setErrorDetails((char *) aSignal->readData(5));
+    theError.details = (char *) aSignal->readData(5);
   }
 
   theStatus = Finished;
Thread
bk commit into 5.1 tree (mskold:1.2588) BUG#21072Martin Skold7 Dec