Below is the list of changes that have just been committed into a local
5.0 repository of psergey. When psergey 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
1.1956 05/08/07 21:32:26 sergefp@stripped +12 -0
Merge spetrunia@stripped:/home/bk/mysql-5.0
into mysql.com:/home/psergey/mysql-5.0-bug11869-part3
sql/sql_union.cc
1.124 05/08/07 21:32:25 sergefp@stripped +0 -0
Auto merged
sql/sql_show.cc
1.262 05/08/07 21:32:25 sergefp@stripped +0 -0
Auto merged
sql/sql_select.cc
1.351 05/08/07 21:32:25 sergefp@stripped +0 -0
Auto merged
sql-common/my_time.c
1.17 05/08/07 21:32:25 sergefp@stripped +0 -0
Auto merged
sql/mysql_priv.h
1.338 05/08/07 21:32:24 sergefp@stripped +0 -0
Auto merged
sql/item_sum.cc
1.157 05/08/07 21:32:24 sergefp@stripped +0 -0
Auto merged
mysql-test/t/rpl_flush_tables.test
1.9 05/08/07 21:32:24 sergefp@stripped +0 -0
Auto merged
mysql-test/t/query_cache.test
1.47 05/08/07 21:32:24 sergefp@stripped +0 -0
Auto merged
mysql-test/r/type_datetime.result
1.28 05/08/07 21:32:24 sergefp@stripped +0 -0
Auto merged
mysql-test/r/query_cache.result
1.62 05/08/07 21:32:24 sergefp@stripped +0 -0
Auto merged
mysql-test/r/create.result
1.97 05/08/07 21:32:24 sergefp@stripped +0 -1
Auto merged
BitKeeper/deleted/.del-not_windows.inc
1.3 05/08/07 21:32:24 sergefp@stripped +0 -0
Auto merged
# 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: sergefp
# Host: newbox.mylan
# Root: /home/psergey/mysql-5.0-bug11869-part3/RESYNC
--- 1.156/sql/item_sum.cc 2005-08-04 19:55:01 +00:00
+++ 1.157/sql/item_sum.cc 2005-08-07 21:32:24 +00:00
@@ -2291,7 +2291,8 @@
DBUG_ASSERT(table == 0);
if (!(table= create_tmp_table(thd, tmp_table_param, list, (ORDER*) 0, 1,
0,
- select_lex->options | thd->options,
+ (select_lex->options | thd->options) &
+ ~TMP_TABLE_FORCE_MYISAM,
HA_POS_ERROR, (char*)"")))
return TRUE;
table->file->extra(HA_EXTRA_NO_ROWS); // Don't update rows
@@ -3073,7 +3074,8 @@
*/
if (!(table= create_tmp_table(thd, tmp_table_param, all_fields,
(ORDER*) 0, 0, TRUE,
- select_lex->options | thd->options,
+ (select_lex->options | thd->options) &
+ ~TMP_TABLE_FORCE_MYISAM,
HA_POS_ERROR, (char*) "")))
DBUG_RETURN(TRUE);
table->file->extra(HA_EXTRA_NO_ROWS);
--- 1.337/sql/mysql_priv.h 2005-08-05 23:34:48 +00:00
+++ 1.338/sql/mysql_priv.h 2005-08-07 21:32:24 +00:00
@@ -256,6 +256,13 @@
#define OPTION_WARNINGS (1L << 13) // THD, user
#define OPTION_AUTO_IS_NULL (1L << 14) // THD, user, binlog
#define OPTION_FOUND_COMMENT (1L << 15) // SELECT, intern, parser
+/*
+ Force the used temporary table to be a MyISAM table (because we will use
+ fulltext functions when reading from it. This uses the same constant as
+ OPTION_FOUND_COMMENT because we've run out of bits and these two values
+ are not used together.
+*/
+#define TMP_TABLE_FORCE_MYISAM (1L << 15)
#define OPTION_SAFE_UPDATES (1L << 16) // THD, user
#define OPTION_BUFFER_RESULT (1L << 17) // SELECT, user
#define OPTION_BIN_LOG (1L << 18) // THD, user
--- 1.350/sql/sql_select.cc 2005-08-04 20:34:40 +00:00
+++ 1.351/sql/sql_select.cc 2005-08-07 21:32:25 +00:00
@@ -1016,7 +1016,7 @@
group_list : (ORDER*) 0),
group_list ? 0 : select_distinct,
group_list && simple_group,
- select_options,
+ select_options & ~TMP_TABLE_FORCE_MYISAM,
(order == 0 || skip_sort_order) ? select_limit :
HA_POS_ERROR,
(char *) "")))
@@ -1396,7 +1396,8 @@
(ORDER*) 0,
curr_join->select_distinct &&
!curr_join->group_list,
- 1, curr_join->select_options,
+ 1, curr_join->select_options
+ & ~TMP_TABLE_FORCE_MYISAM,
HA_POS_ERROR,
(char *) "")))
DBUG_VOID_RETURN;
@@ -8381,7 +8382,7 @@
/* If result table is small; use a heap */
if (blob_count || using_unique_constraint ||
(select_options & (OPTION_BIG_TABLES | SELECT_SMALL_RESULT)) ==
- OPTION_BIG_TABLES)
+ OPTION_BIG_TABLES ||(select_options & TMP_TABLE_FORCE_MYISAM))
{
table->file=get_new_handler(table,table->s->db_type= DB_TYPE_MYISAM);
if (group &&
--- 1.261/sql/sql_show.cc 2005-08-05 09:01:24 +00:00
+++ 1.262/sql/sql_show.cc 2005-08-07 21:32:25 +00:00
@@ -3319,7 +3319,8 @@
if (!(table= create_tmp_table(thd, tmp_table_param,
field_list, (ORDER*) 0, 0, 0,
(select_lex->options | thd->options |
- TMP_TABLE_ALL_COLUMNS),
+ TMP_TABLE_ALL_COLUMNS) &
+ ~TMP_TABLE_FORCE_MYISAM,
HA_POS_ERROR, table_list->alias)))
DBUG_RETURN(0);
table_list->schema_table_param= tmp_table_param;
--- 1.123/sql/sql_union.cc 2005-07-30 01:34:52 +00:00
+++ 1.124/sql/sql_union.cc 2005-08-07 21:32:25 +00:00
@@ -119,8 +119,6 @@
st_select_lex_unit::init_prepare_fake_select_lex(THD *thd)
{
thd->lex->current_select= fake_select_lex;
- fake_select_lex->ftfunc_list_alloc.empty();
- fake_select_lex->ftfunc_list= &fake_select_lex->ftfunc_list_alloc;
fake_select_lex->table_list.link_in_list((byte *)&result_table_list,
(byte **)
&result_table_list.next_local);
@@ -301,15 +299,24 @@
goto err;
}
}
+
+ ulong create_options= (first_select_in_union()->options | thd_arg->options |
+ TMP_TABLE_ALL_COLUMNS) & ~TMP_TABLE_FORCE_MYISAM;
+ /*
+ Force the temporary table to be a MyISAM table if we're going to use
+ fullext functions (MATCH ... AGAINST .. IN BOOLEAN MODE) when reading
+ from it (this should be removed in 5.2 when fulltext search is moved
+ out of MyISAM).
+ */
+ if (global_parameters->ftfunc_list->elements)
+ create_options= create_options | TMP_TABLE_FORCE_MYISAM;
union_result->tmp_table_param.field_count= types.elements;
if (!(table= create_tmp_table(thd_arg,
&union_result->tmp_table_param, types,
(ORDER*) 0, (bool) union_distinct, 1,
- (first_select_in_union()->options |
- thd_arg->options |
- TMP_TABLE_ALL_COLUMNS),
- HA_POS_ERROR, (char *) tmp_table_alias)))
+ create_options, HA_POS_ERROR,
+ (char *) tmp_table_alias)))
goto err;
table->file->extra(HA_EXTRA_WRITE_CACHE);
table->file->extra(HA_EXTRA_IGNORE_DUP_KEY);
| Thread |
|---|
| • bk commit into 5.0 tree (sergefp:1.1956) | Sergey Petrunia | 7 Aug |