mirror of
https://github.com/MariaDB/server.git
synced 2025-12-24 11:21:21 +03:00
After merge fixes of merge with 4.1 that included the new arena code.
Fixed (together with Guilhem) bugs in mysqlbinlog regarding --offset Prefix addresses with 0x for easier comparisons of debug logs Fixed problem where MySQL choosed index-read even if there would be a much better range on the same index This fix changed some 'index' queries to 'range' queries in the test suite Don't create 'dummy' WHERE clause for trivial WHERE clauses where we can remove the WHERE clause. This fix removed of a lot of 'Using where' notes in the test suite. Give NOTE instead of WARNING if table/function doesn't exists when using DROP IF EXISTS Give NOTE instead of WARNING for safe field-type conversions
This commit is contained in:
@@ -1958,6 +1958,20 @@ mysql_execute_command(THD *thd)
|
||||
}
|
||||
#endif /* !HAVE_REPLICATION */
|
||||
|
||||
if (lex->time_zone_tables_used)
|
||||
{
|
||||
TABLE_LIST *tmp;
|
||||
if ((tmp= my_tz_get_table_list(thd, &lex->query_tables_last)) ==
|
||||
&fake_time_zone_tables_list)
|
||||
{
|
||||
send_error(thd, 0);
|
||||
DBUG_RETURN(-1);
|
||||
}
|
||||
lex->time_zone_tables_used= tmp;
|
||||
if (!all_tables)
|
||||
all_tables= tmp;
|
||||
}
|
||||
|
||||
/*
|
||||
When option readonly is set deny operations which change tables.
|
||||
Except for the replication thread and the 'super' users.
|
||||
@@ -2393,11 +2407,11 @@ mysql_execute_command(THD *thd)
|
||||
if (lex->create_info.used_fields & HA_CREATE_USED_UNION)
|
||||
{
|
||||
TABLE_LIST *tab;
|
||||
for (tab= select_tables; tab; tab= tab->next)
|
||||
for (tab= select_tables; tab; tab= tab->next_local)
|
||||
{
|
||||
if (find_real_table_in_list((TABLE_LIST*) lex->create_info.
|
||||
merge_list.first,
|
||||
select_tables->db, tab->real_name))
|
||||
if (find_table_in_local_list((TABLE_LIST*) lex->create_info.
|
||||
merge_list.first,
|
||||
select_tables->db, tab->real_name))
|
||||
{
|
||||
net_printf(thd, ER_UPDATE_TABLE_USED, tab->real_name);
|
||||
goto create_error;
|
||||
@@ -3767,7 +3781,7 @@ purposes internal to the MySQL server", MYF(0));
|
||||
case SP_KEY_NOT_FOUND:
|
||||
if (lex->drop_if_exists)
|
||||
{
|
||||
push_warning_printf(thd, MYSQL_ERROR::WARN_LEVEL_WARN,
|
||||
push_warning_printf(thd, MYSQL_ERROR::WARN_LEVEL_NOTE,
|
||||
ER_SP_DOES_NOT_EXIST, ER(ER_SP_DOES_NOT_EXIST),
|
||||
SP_COM_STRING(lex), lex->spname->m_name.str);
|
||||
res= 0;
|
||||
@@ -4699,7 +4713,7 @@ bool add_field_to_list(THD *thd, char *field_name, enum_field_types type,
|
||||
new_field->sql_type= FIELD_TYPE_BLOB;
|
||||
sprintf(warn_buff, ER(ER_AUTO_CONVERT), field_name, "CHAR",
|
||||
(cs == &my_charset_bin) ? "BLOB" : "TEXT");
|
||||
push_warning(thd, MYSQL_ERROR::WARN_LEVEL_WARN, ER_AUTO_CONVERT,
|
||||
push_warning(thd, MYSQL_ERROR::WARN_LEVEL_NOTE, ER_AUTO_CONVERT,
|
||||
warn_buff);
|
||||
/* fall through */
|
||||
case FIELD_TYPE_BLOB:
|
||||
|
||||
Reference in New Issue
Block a user