mirror of
https://github.com/MariaDB/server.git
synced 2025-08-07 00:04:31 +03:00
Merge mysql.com:/windows/Linux_space/MySQL/mysql-5.0
into mysql.com:/windows/Linux_space/MySQL/mysql-5.0-ndb sql/ha_ndbcluster.cc: Auto merged
This commit is contained in:
@@ -658,3 +658,12 @@ insert into t1 (a, c) values (1,'aaa'),(3,'bbb');
|
|||||||
select count(*) from t1 where c<'bbb';
|
select count(*) from t1 where c<'bbb';
|
||||||
count(*)
|
count(*)
|
||||||
1
|
1
|
||||||
|
create table nationaldish (DishID int(10) unsigned NOT NULL AUTO_INCREMENT,
|
||||||
|
CountryCode char(3) NOT NULL,
|
||||||
|
DishTitle varchar(64) NOT NULL,
|
||||||
|
calories smallint(5) unsigned DEFAULT NULL,
|
||||||
|
PRIMARY KEY (DishID)
|
||||||
|
) ENGINE=ndbcluster;
|
||||||
|
create index i using hash on nationaldish(countrycode,calories);
|
||||||
|
ERROR HY000: Can't create table './test/#sql-3c51_2.frm' (errno: 138)
|
||||||
|
drop table nationaldish;
|
||||||
|
@@ -356,3 +356,17 @@ insert into t1 (a, c) values (1,'aaa'),(3,'bbb');
|
|||||||
select count(*) from t1 where c<'bbb';
|
select count(*) from t1 where c<'bbb';
|
||||||
|
|
||||||
# End of 4.1 tests
|
# End of 4.1 tests
|
||||||
|
|
||||||
|
# bug#24820 CREATE INDEX ....USING HASH on NDB table creates ordered index, not HASH index
|
||||||
|
|
||||||
|
create table nationaldish (DishID int(10) unsigned NOT NULL AUTO_INCREMENT,
|
||||||
|
CountryCode char(3) NOT NULL,
|
||||||
|
DishTitle varchar(64) NOT NULL,
|
||||||
|
calories smallint(5) unsigned DEFAULT NULL,
|
||||||
|
PRIMARY KEY (DishID)
|
||||||
|
) ENGINE=ndbcluster;
|
||||||
|
|
||||||
|
--error ER_CANT_CREATE_TABLE
|
||||||
|
create index i using hash on nationaldish(countrycode,calories);
|
||||||
|
|
||||||
|
drop table nationaldish;
|
||||||
|
@@ -1106,6 +1106,16 @@ int ha_ndbcluster::build_index_list(Ndb *ndb, TABLE *tab, enum ILBP phase)
|
|||||||
error= create_unique_index(unique_index_name, key_info);
|
error= create_unique_index(unique_index_name, key_info);
|
||||||
break;
|
break;
|
||||||
case ORDERED_INDEX:
|
case ORDERED_INDEX:
|
||||||
|
if (key_info->algorithm == HA_KEY_ALG_HASH)
|
||||||
|
{
|
||||||
|
push_warning_printf(current_thd, MYSQL_ERROR::WARN_LEVEL_ERROR,
|
||||||
|
ER_UNSUPPORTED_EXTENSION,
|
||||||
|
ER(ER_UNSUPPORTED_EXTENSION),
|
||||||
|
"Ndb does not support non-unique "
|
||||||
|
"hash based indexes");
|
||||||
|
error= HA_ERR_UNSUPPORTED;
|
||||||
|
break;
|
||||||
|
}
|
||||||
error= create_ordered_index(index_name, key_info);
|
error= create_ordered_index(index_name, key_info);
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
|
Reference in New Issue
Block a user