Many files:
Fix after manual merge mysql-test/r/range.result: Fix after manual merge sql/handler.cc: Fix after manual merge sql/mysql_priv.h: Fix after manual merge sql/opt_range.cc: Fix after manual merge sql/set_var.cc: Fix after manual merge sql/sql_base.cc: Fix after manual merge sql/sql_parse.cc: Fix after manual merge
This commit is contained in:
parent
09e7be1d82
commit
06ecf87e15
@ -215,17 +215,6 @@ select count(*) from t1 where art = 'J';
|
||||
count(*)
|
||||
213
|
||||
drop table t1;
|
||||
create table t1 ( id1 int not null, id2 int not null, idnull int null, c char(20), primary key (id1,id2));
|
||||
insert into t1 values (0,1,NULL,"aaa"), (1,1,NULL,"aaa"), (2,1,NULL,"aaa"),
|
||||
(3,1,NULL,"aaa"), (4,1,NULL,"aaa"), (5,1,NULL,"aaa"),
|
||||
(6,1,NULL,"aaa"), (7,1,NULL,"aaa"), (8,1,NULL,"aaa"),
|
||||
(9,1,NULL,"aaa"), (10,1,NULL,"aaa"), (11,1,NULL,"aaa"),
|
||||
(12,1,NULL,"aaa"), (13,1,NULL,"aaa"), (14,1,NULL,"aaa"),
|
||||
(15,1,NULL,"aaa"), (16,1,NULL,"aaa"), (17,1,NULL,"aaa"),
|
||||
(18,1,NULL,"aaa"), (19,1,NULL,"aaa"), (20,1,NULL,"aaa");
|
||||
select a.id1, b.idnull from t1 as a, t1 as b where a.id2=1 and a.id1=1 and b.id1=a.idnull order by b.id2 desc limit 1;
|
||||
id1 idnull
|
||||
drop table t1;
|
||||
create table t1 (x int, y int, index(x), index(y));
|
||||
insert into t1 (x) values (1),(2),(3),(4),(5),(6),(7),(8),(9);
|
||||
update t1 set y=x;
|
||||
@ -286,6 +275,17 @@ id
|
||||
5
|
||||
9
|
||||
drop table t1;
|
||||
create table t1 ( id1 int not null, id2 int not null, idnull int null, c char(20), primary key (id1,id2));
|
||||
insert into t1 values (0,1,NULL,"aaa"), (1,1,NULL,"aaa"), (2,1,NULL,"aaa"),
|
||||
(3,1,NULL,"aaa"), (4,1,NULL,"aaa"), (5,1,NULL,"aaa"),
|
||||
(6,1,NULL,"aaa"), (7,1,NULL,"aaa"), (8,1,NULL,"aaa"),
|
||||
(9,1,NULL,"aaa"), (10,1,NULL,"aaa"), (11,1,NULL,"aaa"),
|
||||
(12,1,NULL,"aaa"), (13,1,NULL,"aaa"), (14,1,NULL,"aaa"),
|
||||
(15,1,NULL,"aaa"), (16,1,NULL,"aaa"), (17,1,NULL,"aaa"),
|
||||
(18,1,NULL,"aaa"), (19,1,NULL,"aaa"), (20,1,NULL,"aaa");
|
||||
select a.id1, b.idnull from t1 as a, t1 as b where a.id2=1 and a.id1=1 and b.id1=a.idnull order by b.id2 desc limit 1;
|
||||
id1 idnull
|
||||
drop table t1;
|
||||
create table t1 (
|
||||
id int not null auto_increment,
|
||||
name char(1) not null,
|
||||
|
@ -1135,7 +1135,8 @@ int ha_key_cache(KEY_CACHE_VAR *key_cache)
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
int ha_resize_key_cache(KEY_CACHE_VAR *key_cache)
|
||||
{
|
||||
if (key_cache->cache)
|
||||
{
|
||||
pthread_mutex_lock(&LOCK_global_system_variables);
|
||||
|
@ -803,8 +803,7 @@ extern pthread_mutex_t LOCK_mysql_create_db,LOCK_Acl,LOCK_open,
|
||||
LOCK_error_log, LOCK_delayed_insert,
|
||||
LOCK_delayed_status, LOCK_delayed_create, LOCK_crypt, LOCK_timezone,
|
||||
LOCK_slave_list, LOCK_active_mi, LOCK_manager,
|
||||
LOCK_global_system_variables, LOCK_user_conn;
|
||||
LOCK_global_system_variables, LOCK_assign;
|
||||
LOCK_global_system_variables, LOCK_user_conn, LOCK_assign;
|
||||
extern rw_lock_t LOCK_grant;
|
||||
extern pthread_cond_t COND_refresh, COND_thread_count, COND_manager;
|
||||
extern pthread_attr_t connection_attrib;
|
||||
|
@ -895,6 +895,12 @@ get_mm_parts(PARAM *param, Field *field, Item_func::Functype type,
|
||||
if (field->table != param->table)
|
||||
DBUG_RETURN(0);
|
||||
|
||||
if (type == Item_func::NE_FUNC)
|
||||
{
|
||||
ne_func= TRUE;
|
||||
type= Item_func::LT_FUNC;
|
||||
}
|
||||
|
||||
KEY_PART *key_part = param->key_parts;
|
||||
KEY_PART *end = param->key_parts_end;
|
||||
SEL_TREE *tree=0;
|
||||
@ -934,7 +940,7 @@ get_mm_parts(PARAM *param, Field *field, Item_func::Functype type,
|
||||
SEL_TREE *tree2= get_mm_parts(param, field, Item_func::GT_FUNC,
|
||||
value, cmp_type);
|
||||
if (tree2)
|
||||
tree= tree=tree_or(param,tree,tree2);
|
||||
tree= tree_or(param,tree,tree2);
|
||||
}
|
||||
DBUG_RETURN(tree);
|
||||
}
|
||||
|
@ -1597,7 +1597,8 @@ void sys_var_collation_server::set_default(THD *thd, enum_var_type type)
|
||||
|
||||
static LEX_STRING default_key_cache_base= {(char *) DEFAULT_KEY_CACHE_NAME, 7};
|
||||
|
||||
static KEY_CACHE_VAR zero_key_cache= { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 };
|
||||
static KEY_CACHE_VAR zero_key_cache=
|
||||
{ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 };
|
||||
|
||||
static KEY_CACHE_VAR *get_key_cache(LEX_STRING *cache_name)
|
||||
{
|
||||
|
@ -867,7 +867,7 @@ TABLE *open_table(THD *thd,const char *db,const char *table_name,
|
||||
}
|
||||
key_cache_asmt->key_length= key_length;
|
||||
key_cache_asmt->key_cache= &dflt_key_cache_var;
|
||||
VOID(hash_insert(&assign_cache, (byte *) key_cache_asmt));
|
||||
VOID(my_hash_insert(&assign_cache, (byte *) key_cache_asmt));
|
||||
key_cache_asmt->requests++;
|
||||
}
|
||||
key_cache_asmt->to_reassign= 0;
|
||||
|
@ -1906,7 +1906,8 @@ mysql_execute_command(THD *thd)
|
||||
case SQLCOM_ASSIGN_TO_KEYCACHE:
|
||||
{
|
||||
if (check_db_used(thd, tables) ||
|
||||
check_access(thd, INDEX_ACL, tables->db, &tables->grant.privilege))
|
||||
check_access(thd, INDEX_ACL, tables->db,
|
||||
&tables->grant.privilege, 0, 0))
|
||||
goto error;
|
||||
res = mysql_assign_to_keycache(thd, tables);
|
||||
break;
|
||||
@ -1914,7 +1915,8 @@ mysql_execute_command(THD *thd)
|
||||
case SQLCOM_PRELOAD_KEYS:
|
||||
{
|
||||
if (check_db_used(thd, tables) ||
|
||||
check_access(thd, INDEX_ACL, tables->db, &tables->grant.privilege,0,0))
|
||||
check_access(thd, INDEX_ACL, tables->db,
|
||||
&tables->grant.privilege, 0, 0))
|
||||
goto error;
|
||||
res = mysql_preload_keys(thd, tables);
|
||||
break;
|
||||
|
Loading…
x
Reference in New Issue
Block a user